Error while running JSP's on tomcat 4.1.18- org.apache.jasper.JasperExcepti

I am getting the following error when I compile the JSP page. I have set my CLASSPATH correctly, still I am getting the error.Where should I place my class file???
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: 0 in the jsp file: /JspSession_NextPage.jsp
Generated servlet error:
[javac] Compiling 1 source file
D:\Program Files\jakarta-tomcat-4.1.18-LE-jdk14\work\Standalone\localhost\_\JspSession_NextPage_jsp.java:41: cannot resolve symbol
symbol : class UserData
location: class org.apache.jsp.JspSession_NextPage_jsp
UserData user = null;
^
An error occurred at line: 0 in the jsp file: /JspSession_NextPage.jsp
Generated servlet error:
D:\Program Files\jakarta-tomcat-4.1.18-LE-jdk14\work\Standalone\localhost\_\JspSession_NextPage_jsp.java:43: cannot resolve symbol
symbol : class UserData
location: class org.apache.jsp.JspSession_NextPage_jsp
user = (UserData) pageContext.getAttribute("user", PageContext.SESSION_SCOPE);
^
An error occurred at line: 0 in the jsp file: /JspSession_NextPage.jsp
Generated servlet error:
D:\Program Files\jakarta-tomcat-4.1.18-LE-jdk14\work\Standalone\localhost\_\JspSession_NextPage_jsp.java:46: cannot resolve symbol
symbol : class UserData
location: class org.apache.jsp.JspSession_NextPage_jsp
user = (UserData) java.beans.Beans.instantiate(this.getClass().getClassLoader(), "UserData");
^
3 errors
     at org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:130)
     at org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:293)
     at org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:340)
     at org.apache.jasper.compiler.Compiler.compile(Compiler.java:352)
     at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:474)
     at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:184)
     at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
     at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
     at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:260)
     at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
     at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
     at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
     at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
     at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
     at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
     at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
     at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2415)
     at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
     at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
     at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
     at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
     at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172)
     at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
     at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
     at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
     at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
     at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
     at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
     at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
     at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223)
     at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:432)
     at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:386)
     at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:534)
     at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:530)
     at java.lang.Thread.run(Thread.java:536)
Apache Tomcat/4.1.18-LE-jdk14

Have you placed the UserData class in the same directory?

Similar Messages

  • Getting errors while running jsp on sunone web server 6.1

    While i created war file and delpoyed my application on web server6.1, it loads default jsp(welocme.jsp) page fine. but when I submit data it gives me following error.
    [06/Oct/2003:09:17:53] info ( 600): Internal Info: loading servlet /custapprec/bonus.jsp
    [06/Oct/2003:09:17:58] info ( 600): JSP: JSP1x compiler threw exception
    org.apache.jasper.JasperException: Unable to compile class for JSPNote: sun.tools.javac.Main has been deprecated.
    C:\iPlanet\Servers\https-NVS06S-W2K.abc.com\config\..\ClassCache\_jsps\_custapprec\_bonus_jsp.java:63: Class myBean.BonusBean not found.
    myBean.BonusBean Bonus = null;
    ^
    C:\iPlanet\Servers\https-NVS06S-W2K.abc.com\config\..\ClassCache\_jsps\_custapprec\_bonus_jsp.java:65: Class myBean.BonusBean not found.
    Bonus= (myBean.BonusBean)
    ^
    C:\iPlanet\Servers\https-NVS06S-W2K.abc.com\config\..\ClassCache\_jsps\_custapprec\_bonus_jsp.java:69: Class myBean.BonusBean not found.
    Bonus = (myBean.BonusBean) Beans.instantiate(this.getClass().getClassLoader(), "myBean.BonusBean");
    ^
    C:\iPlanet\Servers\https-NVS06S-W2K.abc.com\config\..\ClassCache\_jsps\_custapprec\_bonus_jsp.java:73: Variable Bonus may not have been initialized.
    pageContext.setAttribute("Bonus", Bonus, PageContext.PAGE_SCOPE);
    ^
    4 errors, 1 warning
         at org.apache.jasper.compiler.Compiler.compile(Compiler.java:284)
         at com.iplanet.server.http.servlet.NSServletEntity.load(NSServletEntity.java:252)
         at com.iplanet.server.http.servlet.NSServletEntity.update(NSServletEntity.java:173)
         at com.iplanet.server.http.servlet.NSServletRunner.Service(NSServletRunner.java:427)
    [06/Oct/2003:09:17:58] warning ( 600): Internal error: Failed to get GenericServlet. (uri=/custapprec/bonus.jsp,SCRIPT_NAME=/custapprec/bonus.jsp)
    anybody can please help me with this error?
    Thanks

    Your stack trace indicates classes that are not part of Sun ONE Web Server 6.1 (e.g. com.iplanet.server.http.servlet.NSServletEntity) but are classes in earlier releases of the web server. It looks like your web application contains classes or .jar files that contain an older implementation of the JSP engine from a previous web server release. Remove these and give it another try.

  • Org.apache.jasper.JasperException: Unable to compile class for JSP

    Hi All,
    I have been using NetBeans IDE 3.5.1. AndI am trying to execute one JSP file, but it is giving error and i am not able to execute the servlet files also in NetBeans IDE. Can anybody help me out regarding this...
    type - Exception report
    message - Internal Server Error
    description - The server encountered an internal error (Internal Server Error) that prevented it from fulfilling this request.
    exception -
    org.apache.jasper.JasperException: Unable to compile class for JSP
    C:\Documents and Settings\kiran\.netbeans\3.5\tomcat406_base\work\Tomcat-Internal\localhost\C_3A_5CDocuments+and+Settings_5Ckiran_5CNetBeans+IDE+3.5.1_5Ctomcat406_5Cwebapps_5Cctm\jsp1\AdminClient$jsp.java:5: Package login not found in import.
    import login.*;
    ^
    C:\Documents and Settings\kiran\.netbeans\3.5\tomcat406_base\work\Tomcat-Internal\localhost\C_3A_5CDocuments+and+Settings_5Ckiran_5CNetBeans+IDE+3.5.1_5Ctomcat406_5Cwebapps_5Cctm\jsp1\AdminClient$jsp.java:7: Package javax.ejb not found in import.
    import javax.ejb.*;
    ^
    2 errors
         at org.apache.jasper.compiler.Compiler.compile(Compiler.java:285)
         at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet.loadJSP(IDEJspServlet.java:442)
         at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet$JspServletWrapper.loadIfNecessary(IDEJspServlet.java:148)
         at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet$JspServletWrapper.service(IDEJspServlet.java:160)
         at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet.serviceJspFile(IDEJspServlet.java:246)
         at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet.service(IDEJspServlet.java:339)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
         at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:226)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:213)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:190)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2347)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
         at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:468)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:1027)
         at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1125)
         at java.lang.Thread.run(Thread.java:484)

    The page is located at web/test/test.jsp and the java as below
    Is there anything still need to add to test.jsp?
    DB.java (web/classes/DB/db.class)
    package DB;
    import java.sql.*;
    public class db
    String db_url="jdbc:mysql://localhost:3306/DB";
    String db_user="root";
    String db_password="123456";
    private ResultSet r=null;
    static private ResultSet res=null;
    int staff_Id=0;
    /** Creates a new instance of db */
    public int getRetrieveId()
    try{
         Class.forName("com.mysql.jdbc.Driver").newInstance();
         catch (Exception E)
         E.printStackTrace();
         try{
    Connection C = DriverManager.getConnection(db_url,db_user,db_password);
    Statement S = C.createStatement();
    r = S.executeQuery("select max(staff_Id) from staff");
    while(r.next()){
    staff_Id=r.getInt(1);
    S.close();
    C.close();
    catch(Exception e)
    e.printStackTrace();
    return staff_Id;
    public static boolean getSearch(String s)
    String search_db_url="jdbc:mysql://localhost:3306/DB";
    String search_db_user="root";
    String search_db_password="123456";
    String str=null;
    boolean result=false;
    try{
         Class.forName("com.mysql.jdbc.Driver").newInstance();
         catch (Exception E)
         E.printStackTrace();
         try{
    Connection C = DriverManager.getConnection(search_db_url,search_db_user,search_db_password);
    Statement S = C.createStatement();
    res = S.executeQuery(s);
    while(res.next()){
    str=res.getString(1);
    if(!str.equals(null))
    result=true;
    S.close();
    C.close();
    catch(Exception e)
    e.printStackTrace();
    return result;
    public void setUpdate(String str)
    try{
         Class.forName("com.mysql.jdbc.Driver").newInstance();
         catch (Exception E)
         E.printStackTrace();
         try{
    Connection C = DriverManager.getConnection(db_url,db_user,db_password);
    Statement S = C.createStatement();
    int r = S.executeUpdate(str);
    S.close();
    C.close();
    catch(Exception e)
    e.printStackTrace();
    }

  • Plz help me from the error - "org.apache.jasper.jasperException"

    I am getting error with this code ,plz help me out ,i wanna correct this urgently
    I've set the Environment variables JAVA_HOME and
    CATALINA_HOME and here is my coding and error report
                   hello.html
    <head><title>Database</title></head>
    <body>
    <form method="get" action="add.jsp">
    <pre>
    <center>Enter ur Name :<input type="text" name="nam" >
    <br><input type="submit" value=" Add ">
    </center></pre>
    </form>
    </body>
    </html>
                   add.jsp
    <%@ page language="java" %>
    <%@ page import="java.sql.*" %>
    <html>
    <head><title>JSP</title></head>
    <%! String name;
    Connection con=null;
    Statement st=null;
    %>
    <body>
    <% name=request.getParameter("nam");
    try
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    //I have created a User DSN sjp
    con = DriverManager.getConnection("jdbc:odbc:sjp");
    st = con.createStatement();
    st.executeUpdate("insert into detail values('"+name+"')");
    catch(Exception e)
    con.close();
    st.close();
    %>
    <h1> Name Added</h1>
    </body>
    </html>
                   Error
    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
         at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:207)
         at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:240)
         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:187)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:809)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:200)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:146)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:209)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:144)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2358)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:133)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:118)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:116)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:127)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:152)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
         at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
         at java.lang.Thread.run(Thread.java:534)
    root cause
    java.lang.NullPointerException     at org.apache.jsp.add_jsp._jspService(add_jsp.java:66)
         at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:92)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:809)
         at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:162)
         at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:240)
         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:187)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:809)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:200)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:146)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:209)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:144)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2358)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:133)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:118)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:116)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:127)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:152)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
         at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
         at java.lang.Thread.run(Thread.java:534)
    Apache Tomcat/4.1.31

    hi,
    when i use the code
    if(st != null)st.close();
    if(con != null ) con.close();
    that works good ,the old error has been corrected.
    but it's now throwing an SQLException[b] "datasource name not found and default driver not specified" why this occurs and also can u give me the explanation for the old error????
    I am sure that i have created an user DSN, i am 100% sure about it .even though there is an error.
    Deepak.
    Deepak.C

  • Urgent: HTTP Status 500-org.apache.jasper.JasperException in running websit

    Hi
    I am running a website. The server provided to me is tomcat and is in Linux and database is MYSQL.
    I am getting the below stated error. In my PC the code is running truly but when i upload it to website the following error occured.I have tried with all tomcat jar file and mysql-jdbc connector jar files by putting them in WEB_INF folder.
    I really need this solution in urgent. If any one could help me in solving the problem it would be really Great.
    Thank You.
    type Exception report
    description The server encountered an internal error () that prevented it from fulfilling this request.
    exception
    org.apache.jasper.JasperException
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:373)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    root cause
    java.lang.NullPointerException
         org.apache.jsp.jsp.NewRegistration_jsp._jspService(org.apache.jsp.jsp.NewRegistration_jsp:100)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:99)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:325)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    note The full stack trace of the root cause is available in the Apache Tomcat/5.5.9 logs.

    java.lang.NullPointerException
    org.apache.jsp.jsp.NewRegistration_jsp._jspService(org.apache.jsp.jsp.NewRegistration_jsp:100)
    What is your jsp doing at this point?
    Can you debug it?
    Put a few System.out.println() statements through so you can see at which line it breaks.
    At a guess, seeing as you have mentioned databases, it will probably be related to some database configuration you have done on your local system but not on the server. JNDI setup? Permissions?

  • Org.apache.jasper.JasperException: Error: Attempt to clear a buffer that's

    Hi,
    All I am trying to do is execute a <jsp:forward page=""/> commend. The page I am refering to does exists and three other pages that have the same commend are able to forward to the said page with little issue. All the pages are in the same directory and the path indicator to them is correct. Any help in this matter will be highly appreciated.
    org.apache.jasper.JasperException: Error: Attempt to clear a buffer that's already been flushed
         at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:254)
         at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
         at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2415)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
         at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
         at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:594)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:392)
         at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:565)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:619)
         at java.lang.Thread.run(Thread.java:534)

    jsp:forward always flushes the buffer before proceeding.
    Do you have a statement in your jsp like out.flush() before your use jsp:forward? If you do, try removing it

  • Error on Import Roles Tab (org.apache.jasper.jasperexception)

    Hi all,
    We have installed Edge Standard with SAP IK and create systems for SAP. When I switch over to Import Roles tab, following error is fired:
    org.apache.jasper.jasperexception
    We have copied the relevant JCo sapJCo 2.1.8 files in relevant directories, still the error persist.
    Please advise.
    Regards.

    Hi Ingo,
    Yes, it's tomcat running on Oracle.
    However, the issue is now resolved after installing oracle patch. However, it took us re-installation of oracle since previous oracle installation didn't support the (x86) path, subsequently BOE was also reinstalled along with SAP IK. The issue disappeared this time.
    Regards.
    Mohammad

  • Org.apache.jasper.JasperException error

    Ok here is the problem. I have this war file that works great on my development environment, but when I move it to our QA environment I get the following error:
    org.apache.jasper.JasperException: /custom/search.jsp(29,0) The value for the useBean class attribute lv.me.jse.facade.SearchEngineJavaBean is invalid.
         org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:39)
         org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:357)
         org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:141)
         org.apache.jasper.compiler.Generator$GenerateVisitor.visit(Generator.java:1217)
         org.apache.jasper.compiler.Node$UseBean.accept(Node.java:1116)
         org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
         org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2213)
         org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2219)
         org.apache.jasper.compiler.Node$Root.accept(Node.java:456)
         org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
         org.apache.jasper.compiler.Generator.generate(Generator.java:3261)
         org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:244)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:422)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:507)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:274)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:810)Any Ideas as to why this is happening??

    Is there a difference in environment between the machines?
    Version of java?
    Version of Tomcat?
    Operating System?
    This error is normally generated when
    1 - the class file is invalid
    2 - the bean does not have a PUBLIC no-args constructor
    Are there any libraries that this class would depend on that are on your machine, and not on the the QA machine?

  • Problem with JSF tags, org.apache.jasper.JasperException: Exception in JSP:

    I am a beginner to JSF , I am getting the following error when I try to invoke using the following URL
    http://localhost:8080/Loginjsf/
    I have copied web.xml,faces-config.xml,index.jsp, userLogin.jsp and also the list of jars I am using.
    java version I am using jdk1.5.0_14
    tomcat version 5.5.25
    JSF Version 1.1_01
    ---------------------------------------------------------------------this is the error------------------------------------------------------------------
    exception
    org.apache.jasper.JasperException: Exception in JSP: /index.jsp:7
    4: </head>
    5: <body>
    6: </body>
    7: <jsp:forward page="userLogin.jsp"></jsp:forward>
    8: </html>
    Stacktrace:
         org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:451)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:355)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    root cause
    org.apache.jasper.JasperException: Exception in JSP: /userLogin.jsp:15
    12: </head>
    13:
    14: <body>
    15:      <f:view>
    16:           <h:form id="UserName">
    17:           <f:loadBundle basename ="com.demo.MessageBundle" var="bundle"/> <br>
    18:                     <h:inputText></h:inputText>
    Stacktrace:
         org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:451)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:355)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:686)
         org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:656)
         org.apache.jsp.index_jsp._jspService(index_jsp.java:50)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    root cause
    javax.servlet.ServletException: Cannot find FacesContext
         org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:841)
         org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:774)
         org.apache.jsp.userLogin_jsp._jspService(userLogin_jsp.java:92)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:686)
         org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:656)
         org.apache.jsp.index_jsp._jspService(index_jsp.java:50)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    root cause
    javax.servlet.jsp.JspException: Cannot find FacesContext
         javax.faces.webapp.UIComponentTag.doStartTag(UIComponentTag.java:399)
         com.sun.faces.taglib.jsf_core.ViewTag.doStartTag(ViewTag.java:105)
         org.apache.jsp.userLogin_jsp._jspx_meth_f_005fview_005f0(userLogin_jsp.java:107)
         org.apache.jsp.userLogin_jsp._jspService(userLogin_jsp.java:82)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:686)
         org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:656)
         org.apache.jsp.index_jsp._jspService(index_jsp.java:50)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    THE WEB.XML FILE I AM USING IS
    The web.xml, faces-config.xml files which I am using ,
    <?xml version='1.0' encoding='UTF-8'?>
    <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
    <web-app>
    <context-param>
    <param-name>javax.faces.CONFIG_FILES</param-name>
    <param-value>/WEB-INF/faces-config.xml</param-value>
    </context-param>
    <context-param>
    <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
    <param-value>.xhtml</param-value>
    </context-param>
    <context-param>
    <param-name>com.sun.faces.validateXml</param-name>
    <param-value>true</param-value>
    <description>
    Set this flag to true if you want the JavaServer Faces
    Reference Implementation to validate the XML in your
    faces-config.xml resources against the DTD. Default
    value is false.
    </description>
    </context-param>
    <servlet>
    <servlet-name>Faces Servlet</servlet-name>
    <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
    <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
    <servlet-name>Faces Servlet</servlet-name>
    <url-pattern>*.faces</url-pattern>
    </servlet-mapping>
    <welcome-file-list>
    <welcome-file>index.jsp</welcome-file>
    </welcome-file-list>
    <!--Tomcat 5 Workaround: Listener used to initialize JSF on startup-->
         <listener>
              <listener-class>com.sun.faces.config.ConfigureListener</listener-class>
         </listener>
    </web-app>
    THE FACES-CONFIG.XML I AM USING
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN" "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
    <faces-config >
         <application>
              <view-handler>com.sun.facelets.FaceletViewHandler</view-handler>
         </application>
         <managed-bean>
              <managed-bean-name>UserBean</managed-bean-name>
              <managed-bean-class>com.demo.bean.UserBean</managed-bean-class>
              <managed-bean-scope>session</managed-bean-scope>
              <managed-property>
                   <property-name>userName</property-name>
                   <property-class>java.lang.String</property-class>
                   <value></value>
              </managed-property>
              <managed-property>
                   <property-name>password</property-name>
                   <property-class>java.lang.String</property-class>
                   <value></value>
              </managed-property>
         </managed-bean>
         <navigation-rule>
              <from-view-id>/userLogin.jsp</from-view-id>
              <navigation-case><from-outcome>failure</from-outcome>
                   <to-view-id>/loginForm.jsp</to-view-id>
              </navigation-case>
              <navigation-case>
                   <from-action>success</from-action>
                   <to-view-id>/userLoginSuccess.jsp</to-view-id>
              </navigation-case></navigation-rule>
         <navigation-rule>
              <from-view-id>/userLoginSuccess.jsp</from-view-id>
         </navigation-rule>
         <navigation-rule>
              <from-view-id>/loginForm.jsp</from-view-id>
         </navigation-rule>
         </faces-config>
    THE INDEX.JSP I AM USING
    <%@ page contentType="text/html;charset=UTF-8" language="java" %>
    <html>
    <head>
    </head>
    <body>
    </body>
    <jsp:forward page="userLogin.jsp"></jsp:forward>
    </html>
    THE USERLOGIN.JSP is
    <%@ page language="java" pageEncoding="ISO-8859-1"%>
    <%@ taglib uri="/WEB-INF/html_basic.tld" prefix="h"%>
    <%@ taglib uri="/WEB-INF/jsf_core.tld" prefix="f"%>
    <html>
    <head>
    <title>My JSF 'userLogin' starting page</title>
         <!--
         <link rel="stylesheet" type="text/css" href="styles.css">
         -->
    </head>
    <body>
    <f:view>
    <h:form id="UserName">
         <f:loadBundle basename ="com.demo.MessageBundle" var="bundle"/> <br>
              <h:inputText></h:inputText>
              <h:outputLabel value="UserName"></h:outputLabel>
              <h:inputText></h:inputText>
              <h:outputLabel for="Password" value="Password" id="Password"></h:outputLabel>
    </h:form>
    </f:view>
    </body>
    </html>
    THE JAR FILES LOCATED AT tomcat-5.5\webapps\Loginjsf\WEB-INF\lib
    commons-beanutils.jar
    commons-collections.jar
    commons-digester.jar
    commons-logging.jar
    el-api.jar
    el-ri.jar
    jsf-api.jar
    jsf-facelets.jar
    jsf-impl.jar
    jstl.jar
    standard.jar
    It would be great if you could help me in resolving this problem, what is that I am doing wrong?

    Thanks for your suggestions, I updated the web.xml and index.jsp accordingly but this time I am getting a different kind of error as below
    org.apache.jasper.JasperException: Exception in JSP: /index.jsp:6
    3: <head>
    4: </head>
    5: <body>
    6: <jsp:forward page="userLogin.faces"></jsp:forward>
    7: </body>
    8: </html>
    Stacktrace:
         org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:451)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:355)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    root cause
    javax.servlet.ServletException: Error Parsing /userLogin.jsp: Error Traced[line: 1] The markup in the document preceding the root element must be well-formed.
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:202)
         org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:686)
         org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:656)
         org.apache.jsp.index_jsp._jspService(index_jsp.java:49)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    root cause
    com.sun.facelets.FaceletException: Error Parsing /userLogin.jsp: Error Traced[line: 1] The markup in the document preceding the root element must be well-formed.
         com.sun.facelets.compiler.SAXCompiler.doCompile(SAXCompiler.java:234)
         com.sun.facelets.compiler.Compiler.compile(Compiler.java:105)
         com.sun.facelets.impl.DefaultFaceletFactory.createFacelet(DefaultFaceletFactory.java:197)
         com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:144)
         com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:95)
         com.sun.facelets.FaceletViewHandler.buildView(FaceletViewHandler.java:496)
         com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:546)
         com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
         com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
         org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:686)
         org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:656)
         org.apache.jsp.index_jsp._jspService(index_jsp.java:49)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

  • Tomcat - org.apache.jasper.JasperException: Cannot find FacesContext

    I'm using JSC for develop, i'm totally newbie.
    I've search in documentation and in this forum for a solution to develop directly in tomcat. I've applicate all kind of solution i've found and step by step thigs goes better.
    Now I'm stopped here... someone can help me?
    Thaks a lot, Ebolo.
    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: Cannot find FacesContext
         org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:512)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:377)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    root cause
    javax.servlet.ServletException: Cannot find FacesContext
         org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:843)
         org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:776)
         org.apache.jsp.Page1_jsp._jspService(Page1_jsp.java:104)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    root cause
    javax.servlet.jsp.JspException: Cannot find FacesContext
         javax.faces.webapp.UIComponentTag.doStartTag(UIComponentTag.java:405)
         com.sun.faces.taglib.jsf_core.ViewTag.doStartTag(ViewTag.java:105)
         org.apache.jsp.Page1_jsp._jspx_meth_f_view_0(Page1_jsp.java:119)
         org.apache.jsp.Page1_jsp._jspService(Page1_jsp.java:97)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

    Both jar are ok, my web.xml follow
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="2.4" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
    <context-param>
        <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
        <param-value>server</param-value>
      </context-param>
    <context-param>
        <param-name>javax.faces.CONFIG_FILES</param-name>
        <param-value>/WEB-INF/navigation.xml,/WEB-INF/managed-beans.xml</param-value>
      </context-param>
    <context-param>
        <param-name>com.sun.faces.validateXml</param-name>
        <param-value>true</param-value>
      </context-param>
    <context-param>
        <param-name>com.sun.faces.verifyObjects</param-name>
        <param-value>false</param-value>
      </context-param>
    <filter>
        <filter-name>UploadFilter</filter-name>
        <filter-class>com.sun.rave.web.ui.util.UploadFilter</filter-class>
        <init-param>
          <description>
              The maximum allowed upload size in bytes.  If this is set
              to a negative value, there is no maximum.  The default
              value is 1000000.
            </description>
          <param-name>maxSize</param-name>
          <param-value>1000000</param-value>
        </init-param>
        <init-param>
          <description>
              The size (in bytes) of an uploaded file which, if it is
              exceeded, will cause the file to be written directly to
              disk instead of stored in memory.  Files smaller than or
              equal to this size will be stored in memory.  The default
              value is 4096.
            </description>
          <param-name>sizeThreshold</param-name>
          <param-value>4096</param-value>
        </init-param>
      </filter>
    <filter-mapping>
        <filter-name>UploadFilter</filter-name>
        <servlet-name>Faces Servlet</servlet-name>
      </filter-mapping>
    <servlet>
        <servlet-name>Faces Servlet</servlet-name>
        <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
      </servlet>
    <servlet>
        <servlet-name>ThemeServlet</servlet-name>
        <servlet-class>com.sun.rave.web.ui.theme.ThemeServlet</servlet-class>
      </servlet>
    <servlet-mapping>
        <servlet-name>Faces Servlet</servlet-name>
        <url-pattern>/faces/*</url-pattern>
      </servlet-mapping>
    <servlet-mapping>
        <servlet-name>ThemeServlet</servlet-name>
        <url-pattern>/theme/*</url-pattern>
      </servlet-mapping>
    <welcome-file-list>
        <welcome-file>faces/Page1.jsp</welcome-file>
      </welcome-file-list>
    <jsp-config>
        <jsp-property-group>
          <url-pattern>*.jspf</url-pattern>
          <is-xml>true</is-xml>
        </jsp-property-group>
      </jsp-config>
    </web-app>

  • Org.apache.jasper.JasperException Ambigous Class Error

    I included two classes:
    <% @page import = "com.myco.ejb.ThisBean" %>
    <% @page import = "com.myco.ejb.session.ThisBean" %>
    and received an org.apache.jasper.JasperException Ambigous Class Error on the second import. One is a cmp bean, the other is a session bean. I thought Sun wanted us to name our packages like this to aid in the prevention of duplicate class names (i.e., Windoz DLLitus). Shouldn't these classes be unique by the package name?

    No, that's not redundancy. Are you using the fully qualified class name in your jsp:usebean tags?
    like:
    classname="com.mypackage.mybeans.MyBean"
    And are you using the package statement properly in your source?
    In the case that you are using two classes of the same name in one file the compiler has to have a means of distinguishing between the two. The only way for it to do so is to use the fully qualified name of the class in each case in which it is referenced. This means either in the jsp:usebean tag as shown above, or in such a case as:
    com.mypackage.myclasses.MyClass theOb=new com.mypackage.myclasses.MyClass();
    Awkward yes, but ambiguous No.
    In the case where you are using only one class of a given name the import statement will be sufficient for the compiler to know that it is that which you fully qualify in the import statement.
    Remember, all that the import statement does is provide the convenience of pre-clarifying exactly which class you'll be referring to when using the abbreviated class name only. Importing two classes of the same name defeats the purpose.
    Good luck,
    Brad

  • Error org.apache.jasper.JasperException: null

    Hello,
    I am working with an application trying to execute something in a JSP (or servlet too, getting the same error) and at the time the JSP finish all the work and try to redirect the response, I got the error below.
    Please any idea would be very, very, helpful.
    The code executed is:
    request.getRequestDispatcher("/ThresholdsTransactions.jsp").forward(request,response);The page ThresholdsTransactions.jsp exist, is the source where I call the page that give me the error.
    The error is:
    org.apache.jasper.JasperException: null
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:358)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         org.apache.jsp.StatusHandler_jsp._jspService(StatusHandler_jsp.java:111)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:133)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:311)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
    root cause
    java.lang.NumberFormatException: null
         java.lang.Integer.parseInt(Integer.java:436)
         java.lang.Integer.<init>(Integer.java:609)
         org.apache.jsp.ThresholdsTransactions_jsp._jspService(ThresholdsTransactions_jsp.java:101)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:133)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:311)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         org.apache.jsp.StatusHandler_jsp._jspService(StatusHandler_jsp.java:111)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:133)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:311)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:856)

    root cause
    java.lang.NumberFormatException: null
    java.lang.Integer.parseInt(Integer.java:436)It certainly appears that you're using Integer.parseInt somewhere, if you're not, then maybe a call you're making is. Maybe use some SOP's to try and trace the line at which this is occuring?

  • Jsp org.apache.jasper.JasperException: Cannot forward after response has be

    what does this mean?
    org.apache.jasper.JasperException: Cannot forward after response has been committed
    I can't find an explanation of the error in general on the web? I am using dispatcher.,forward?
    <%@ page import="java.io.*" %>
    <%@ page import="javax.servlet.*" %>
    <%@ page import="javax.servlet.http.*" %>
    <%@ page import="java.util.*" %>
    <%@ page import="java.text.*" %>
    <%@ page import="javax.xml.parsers.DocumentBuilderFactory" %>
    <%@ page import="javax.xml.parsers.*" %>
    <%@ page import="org.w3c.dom.Document" %>
    <%@ page import="org.w3c.dom.DOMException" %>
    <%@ page import="org.w3c.dom.Element" %>
    <%@ page language="java" import=".*" %>
    <jsp:useBean id="manageAddressBook" scope="session" class=".ManageAddressBook" />
    <%! .AddressBook ab; %>
    <%! //String addJSP = "http://localhost:8080/examples/jsp//display.jsp"; %>
    <%! String addJSP = "Add.jsp"; %>
    <%! String displayJSP = "display.jsp"; %>
    <%! boolean noPrev = false; %>
    <% String displayPage = "display.jsp";
       String addPage     = "Add.jsp";
       String loginPage   = "login.jsp";
    Enumeration enum = request.getParameterNames();
    AddressBook ab;
    String lastPageVar = request.getParameter("lastPageVar");
    String button = (String)request.getParameter("submit");
    if (lastPageVar == null)
       lastPageVar = "";
    //Figure out what the dispatcher needs to do
    String actionVar = request.getParameter("actionVar");
      if (actionVar == null)
         actionVar = "";
    //check login status
    Object loginObj = session.getAttribute("isLoggedIn");
    boolean isLoggedIn;
    if (loginObj != null)
       isLoggedIn = ((Boolean) loginObj).booleanValue();
    else
       isLoggedIn = false;
    if (lastPageVar.equals("")){
       session.setAttribute ("fromDispatcher", new Boolean(true));
       session.setAttribute("firstCall", new Boolean(false));
       callWebPage(request,response,session,loginPage);
    else
       session.setAttribute("firstCall", new Boolean(false));
    //if (!(isLoggedIn))
    //  callWebPage(request,response,session,loginPage);
    if (lastPageVar.equals("LOGIN_PAGE")){
       String username = (String)request.getParameter("username");
       String password = (String)request.getParameter("password");
       isLoggedIn = checkLogin(username,password);
       Boolean isLoggedInObj = new Boolean(isLoggedIn);
       session.setAttribute ("isLoggedIn", isLoggedInObj);
       if (isLoggedIn)
         callWebPage(request,response,session,displayPage);
       else
         callWebPage(request,response,session,loginPage);
    if (lastPageVar.equals("DISPLAY_PAGE")){
      if (button.equals("logout"))
        callWebPage(request,response,session,loginPage);
      if (button.equals("next") || button.equals("previous"))
        callWebPage(request,response,session,displayPage);
      else
        callWebPage(request,response,session,addPage);
    if (lastPageVar.equals("ADD_PAGE")){
      if (button.equals("logout"))
         callWebPage(request,response,session,loginPage);
      //if save or cancel, then just save or cancel and return to display screen.
      if (button.equals("save")){
        manageAddressBook.edit(request);
        callWebPage(request,response,session,displayPage);
      if (button.equals("Add"))
        callWebPage(request,response,session,displayPage);
      else
        ab = (AddressBook)session.getAttribute("currAddressBook");
      if (button.equals("Delete")) {
        ab = (AddressBook)session.getAttribute("currAddressBook");
        manageAddressBook.setDelete(ab);
        callWebPage(request,response,session,displayPage);
      if (button.equals("cancel"))
        callWebPage(request,response,session,displayPage);
    %>
    <%-- JSP FUNCTIONS  --%>
    <%!
    public boolean checkLogin(String username, String password) {
       if (username.equals("mypage") && password.equals("guesswho"))
         return true;
       else
         return false;
    void callWebPage( HttpServletRequest request,HttpServletResponse response,HttpSession session,String webPage)
        throws ServletException, IOException {
      //verifies from dispather
      session.setAttribute ("fromDispatcher", new Boolean(true));
      RequestDispatcher dispatch = request.getRequestDispatcher( webPage );
      dispatch.forward(request,response);
    %>

    Its like this.. after you dispatch the request by the method call [callWeb...], the dispatcher would dispatch the request to that page and after the page is dispatched and response has been sent, the execution continues on this JSP, ie from the line after the call to the [callWeb..] function.. All you need to do to avoid this exception is,
    a) put a return; statement after the call to the function.
    Or
    b) structure your code in such a way that after the call to the [callWeb..] function, the execution would not continue;
    I would prefer the first condition though along with structuring the code in such a way that you need not have that many calls to the function. Instead have a String dest variable, which would change and make a call in the end
    Cheers
    -P

  • I got org.apache.jasper.JasperException:quote symbol expected error

    Hi Proffesionals
    iam new working with spring
    i got an error
    org.apache.jasper.JasperException:/WEB-INF/showjsps/showmsg.jsp(3,28)quote symbol expected error
    how can i handle this error
    any one can help me please
    regards

    Hi dvohra,
    Thanks for ur reply.
    I guess my problem has got to do more with the oracle error-
    ORA-00600: internal error code, arguments: [ttcgcshnd-1], [0], [], [], [], [], [], []
    I believe jasper is just throwing the exception caught from oracle error. Please let me know if u think otherwise.
    Can you help me in handling this ORA-0600 with the above mentioned arguments.
    I basically, would like to know in which directory the JDBC driver go, if i use tomcat4 server and do I have to set the system classpathand PATH for the driver location.
    Also which driver should I use to connect to remote DB- Oracle 9.2.0.5.0 (I have Ora 8i in my local machine) when using JDK1.4. (SHOULD I ALSO HAVE THE OTHER JAR files LIKE THE "CHARSET" IN THE LOCATION WHERE THE MAIN DRIVER FILE IS STORED.)
    Thanks,
    Karthik.

  • Org.apache.jasper.JasperException; JCO error when Importing SAP Roles in C

    Hello experts,
    I have installed BOXI 3.1 SP3, Integration kit SP2, BW/BI 7.0 and ECC 6.0 on Windows 2008/64bit.
    My goal is to import the roles into CMS from SAP BW/BI but getting the follwoing errors:
    JCO.classInitialize(): Could not load middleware layer 'com.sap.mw.jco.rfc.MiddlewareRFC'
    JCO.nativeInit(): Could not initialize dynamic link library sapjcorfc
    C:\Windows\SysWOW64\sapjcorfc.dll: Can't load AMD 64-bit .dll on a IA 32-bit platform.
    java.library.path [C:\Windows\SysWOW64\;D:\Business Objects\BusinessObjects Enterprise 12.0\win32_x86\]
    org.apache.jasper.JasperException
    I followed the note 1292144 - JCO error when Importing SAP Roles in CMC,but unfortunately without success.
    I installed SAP JCo Release 2.1.9 (64bit)
    Best regards
    Lutz
    Edited by: Lutz Heinrich on Aug 12, 2010 4:17 PM

    Install the 32bit version of the Java connector. BOBJ is 32bit so even on 64bit Windows you need the 32bit version of the Java Connector.
    Regards,
    Stratos

Maybe you are looking for