Solved

Tomcat: getting error "PopulateSpreadsheet cannot be resolved to a type"

Posted on 2011-02-23
3
576 Views
Last Modified: 2012-06-21
I have a jsp page that uses a class library located in the classes/pikefin folder. In the JPS page it is being imported with this line:
<%@ page import="pikefin.*" %>

BTW, this was all working fine until I changed some code in the class library and recompiled.

Here is the full error message from the tomcat log:
 
SEVERE: Servlet.service() for servlet jsp threw exception
java.lang.ClassNotFoundException: org.apache.jsp.jsp.JSPEssbase2.essbasedatasource_jsp
        at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
        at org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:134)
        at org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:66)
        at org.apache.jasper.JspCompilationContext.load(JspCompilationContext.java:628)
        at org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:144)
        at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:329)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)

Open in new window


I checked the permissions on the .class files in :
/var/lib/tomcat6/webapps/JSPEssbase2/WEB-INF/classes/pikefin

and they are all set to 777.

I've restarted tomcat several times.
0
Comment
Question by:opike
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 

Author Comment

by:opike
ID: 34962216
Sorry, that error message I gave before is further down the log file.

This is the part that appears before that:
Feb 23, 2011 9:30:48 AM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet jsp threw exception
org.apache.jasper.JasperException: Unable to compile class for JSP:

An error occurred at line: 15 in the jsp file: /jsp/JSPEssbase2/essbasedatasource.jsp
PopulateSpreadsheet cannot be resolved to a type
12: <body>
13: <%
14: out.println(" Hello Oracle World5");
15: PopulateSpreadsheet tmp = new PopulateSpreadsheet();
16:
17: ArrayList<String[]> tmpArrayList = tmp.getArrayList();
18:

Open in new window


And a similar message appears in the browser:
An error occurred at line: 15 in the jsp file: /jsp/JSPEssbase2/essbasedatasource.jsp
PopulateSpreadsheet cannot be resolved to a type
12: <body>
13: <% 
14: out.println(" Hello Oracle World5");
15: PopulateSpreadsheet tmp = new PopulateSpreadsheet();
16: 
17: ArrayList<String[]> tmpArrayList = tmp.getArrayList();
18: 


Stacktrace:
	org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:92)
	org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)
	org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:439)
	org.apache.jasper.compiler.Compiler.compile(Compiler.java:349)

Open in new window

0
 
LVL 47

Accepted Solution

by:
for_yan earned 500 total points
ID: 34962268
0
 

Author Comment

by:opike
ID: 34962359
Yeah... I know I had it working and then it stopped all of sudden. But now I realized what the problem was, the browser was using a cached older url that was only slightly different and I didn't noticed the difference until now.
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This exercise is about for the following scenario: Dmgr and One node with 2 application server. Each application server contains it owns application. Application server name as follows server1 contains app1 server2 contains app1 Prereq…
Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…
This video teaches viewers about errors in exception handling.
Suggested Courses

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question