Olá galera, estou com o seguinte problema, criei uma aplicação em jsp, fiz todos os testes e estava tudo funcionando certinho porém quando eu coloco no servidor (linux) ele funciona tudo só que quando eu tento usar uma determinada classe ele da esse erro:
HTTP Status 500 -
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
org.apache.jasper.JasperException: Unable to compile class for JSP:
An error occurred at line: 49 in the jsp file: /jsp/osGlobal.jsp
utilitarios.ContadorPage cannot be resolved to a type
46: %>
47:
48:
49: <%! utilitarios.ContadorPage os;%>
50: <%! int conta;%>
51:
52:
An error occurred at line: 54 in the jsp file: /jsp/osGlobal.jsp
os cannot be resolved
51:
52:
53: <%
54: os = new utilitarios.ContadorPage(application.getRealPath(“counter.dat”));
55: conta = os.getCount();
56: %>
57: <!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 4.01 Transitional//EN”
An error occurred at line: 54 in the jsp file: /jsp/osGlobal.jsp
utilitarios.ContadorPage cannot be resolved to a type
51:
52:
53: <%
54: os = new utilitarios.ContadorPage(application.getRealPath(“counter.dat”));
55: conta = os.getCount();
56: %>
57: <!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 4.01 Transitional//EN”
An error occurred at line: 55 in the jsp file: /jsp/osGlobal.jsp
os cannot be resolved
52:
53: <%
54: os = new utilitarios.ContadorPage(application.getRealPath(“counter.dat”));
55: conta = os.getCount();
56: %>
57:
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:423)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:317)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:282)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:586)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
java.lang.reflect.Method.invoke(Method.java:616)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:244)
java.security.AccessController.doPrivileged(Native Method)
javax.security.auth.Subject.doAsPrivileged(Subject.java:537)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:276)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:162)
note The full stack trace of the root cause is available in the Apache Tomcat/6.0.18 logs.
Apache Tomcat/6.0.18
toda parte de CRUD funciona só nessa classe que não alguém pode dar uma luz? valew!
L.Bach
Dezembro 29, 2009, 11:04am
#2
Olá,
Deve estar faltando um <%@ page import=“utilitarios.ContadorPage” %>
Abraço