Cannot compile JSP pages in Tomcat 5.0.28

Hi,
I'm new to Tomcat and this has been bothering me for days now.
I have (seemingly) correctly installed Tomcat v5.0.28 and am currently in the process of testing my environment with simple html/jsp pages.
My server starts up fine with no error messages.
Testing the server I can access the .html file fine, however I get a HTTP 404 error for the .jsp: The requested resource (/hello/hello.jsp) is not availableI have done the following since installation:
1. Installed Tomcat to C:\Program Files\jakarta-tomcat-5.0.282. Set the environment variable JAVA_HOME to the value C:\Program Files\Java\jdk1.5.0 (base directory of my java installation)
3. Even added ;C:\Program Files\Java\jdk1.5.0\bin to the environment variable Path (just in case, for javac)
4. Enabled the invoker sevlet by uncommenting:
    <servlet>
        <servlet-name>invoker</servlet-name>
        <servlet-class>
          org.apache.catalina.servlets.InvokerServlet
        </servlet-class>
    </servlet>and
    <servlet-mapping>
        <servlet-name>invoker</servlet-name>
        <url-pattern>/servlet/*</url-pattern>
    </servlet-mapping>in conf/web.xml
5. Added an access log valve to locahost
6. Set ant fork compiles to seperate JVMs:
    <servlet>
        <servlet-name>jsp</servlet-name>
        <servlet-class>org.apache.jasper.servlet.JspServlet</servlet-class>
        <init-param>
            <param-name>fork</param-name>
            <param-value>true</param-value>
        </init-param>
        <init-param>
            <param-name>xpoweredBy</param-name>
            <param-value>false</param-value>
        </init-param>
        <load-on-startup>3</load-on-startup>
    </servlet>6. Installed the .html and .jsp pages to folder %CATALINA_HOME%/webapps/ROOT/helloNow when I bin/startup.bat Tomcat starts without anu error messges. In a browser I can now access http://localhost:8080 and http://localhost:8080/hello/hello.html but not http://localhost:8080/hello/hello.jspHere are my logfiles (in debug mode) for performing the above actions and then shutting down:
catalina_log.txt
2006-04-29 18:29:02 EngineConfig: EngineConfig: Processing START
2006-04-29 18:29:24 EngineConfig: EngineConfig: Processing STOPlocalhost_log.txt
2006-04-29 18:29:01 StandardContext[/balancer]org.apache.webapp.balancer.BalancerFilter: init(): ruleChain: [org.apache.webapp.balancer.RuleChain: [org.apache.webapp.balancer.rules.URLStringMatchRule: Target string: News / Redirect URL: http://www.cnn.com], [org.apache.webapp.balancer.rules.RequestParameterRule: Target param name: paramName / Target param value: paramValue / Redirect URL: http://www.yahoo.com], [org.apache.webapp.balancer.rules.AcceptEverythingRule: Redirect URL: http://jakarta.apache.org]]
2006-04-29 18:29:01 StandardContext[/jsp-examples]ContextListener: contextInitialized()
2006-04-29 18:29:01 StandardContext[/jsp-examples]SessionListener: contextInitialized()
2006-04-29 18:29:02 StandardContext[/servlets-examples]ContextListener: contextInitialized()
2006-04-29 18:29:02 StandardContext[/servlets-examples]SessionListener: contextInitialized()
2006-04-29 18:29:24 StandardContext[/servlets-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@14eaec9')
2006-04-29 18:29:24 StandardContext[/servlets-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@b533b8')
2006-04-29 18:29:24 StandardContext[/servlets-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@569c60')
2006-04-29 18:29:24 StandardContext[/servlets-examples]SessionListener: contextDestroyed()
2006-04-29 18:29:24 StandardContext[/servlets-examples]ContextListener: contextDestroyed()
2006-04-29 18:29:24 StandardContext[/jsp-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@d67067')
2006-04-29 18:29:24 StandardContext[/jsp-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@6db724')
2006-04-29 18:29:24 StandardContext[/jsp-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@112da40')
2006-04-29 18:29:24 StandardContext[/jsp-examples]SessionListener: contextDestroyed()
2006-04-29 18:29:24 StandardContext[/jsp-examples]ContextListener: contextDestroyed()localhost_access_log.txt
127.0.0.1 - - [29/Apr/2006:18:29:13 +0930] "GET /hello/hello.html HTTP/1.1" 304 -
127.0.0.1 - - [29/Apr/2006:18:29:19 +0930] "GET /hello/hello.jsp HTTP/1.1" 404 1000Also, my sourced test .html and .jsp files:
hello.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!--
Simple HTML file to test server setup and configuration.
Taken from Core Servlets and JavaServer Pages 2nd Edition
from Prentice Hall and Sun Microsystems Press,
http://www.coreservlets.com/.
(C) 2003 Marty Hall; may be freely used or adapted.
-->
<HTML>
<HEAD><TITLE>HTML Test</TITLE></HEAD>
<BODY BGCOLOR="#FDF5E6">
<H1>HTML Test</H1>
Hello.
</BODY></HTML>hello.jsp
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!--
Simple JSP file to test server setup and configuration.
Taken from Core Servlets and JavaServer Pages 2nd Edition
from Prentice Hall and Sun Microsystems Press,
http://www.coreservlets.com/.
(C) 2003 Marty Hall; may be freely used or adapted.
-->
<HTML>
<HEAD><TITLE>JSP Test</TITLE></HEAD>
<BODY BGCOLOR="#FDF5E6">
<H1>JSP Test</H1>
Time: <%= new java.util.Date() %>
</BODY></HTML>I am getting so frustrated I feel like I have tried everything...

Thanks for your feedback, I tried all suggestions but still no luck.
One thing I didn't mention previously was I have also tried the following (note: I have omitted the prefix "%CATALINA_HOME%/webapps"
to all directory references below):
1. installed my .jsp directly into /ROOT
2. installed my .jsp into subdirectory /ROOT/hello
3. installed my .jsp into /root_copy (identified as a running application by Tomcat manager)
I think there must a problem in my deployment because the JSP examples (http://localhost:8080/jsp-examples/) compile fine...
This indicates that JAVA_HOME is set correctly.
Since my first post I tried installing tomcat from a windows installer into c:\apache\tomcat5.0.28\ and set logging to debug.
Here's a small dump of 5 logs in localhost_log.2006-05-01.txt:
2006-05-01 20:08:31 StandardContext[/balancer]org.apache.webapp.balancer.BalancerFilter]...
2006-05-01 20:08:32 StandardContext[/jsp-examples]ContextListener: contextInitialized()
2006-05-01 20:08:32 StandardContext[/jsp-examples]SessionListener: contextInitialized()
2006-05-01 20:08:32 StandardContext[/servlets-examples]ContextListener: contextInitialized()
2006-05-01 20:08:32 StandardContext[/servlets-examples]SessionListener: contextInitialized()Note there was no initialization of the context root_copy, but I'm unsure if there's any relevance here or not.

Similar Messages

  • Problem in running a jsp page on tomcat 5.0

    hi....
    i made a java class abc.java and then compiled it to get a java class file named abc.class in a package named pkg.
    Then i copied this package in the classes folder of the WEB-INF folder in tomcat 5.0.
    After that i created a jsp page in which i imported this class file. Now when i run the jsp page on tomcat 5.0 i get an error saying this:
    javax.servlet.ServletException: pkg/abc (Unsupported major.minor version 49.0)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:244)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    root cause
    java.lang.UnsupportedClassVersionError: pkg/abc (Unsupported major.minor version 49.0)
         java.lang.ClassLoader.defineClass0(Native Method)
         java.lang.ClassLoader.defineClass(ClassLoader.java:502)
         java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
         org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1634)
         org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:860)
         org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1307)
         org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1189)
         org.apache.jasper.compiler.Generator$GenerateVisitor.visit(Generator.java:1214)
         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:3272)
         org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:244)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:495)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:476)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:464)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:511)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:295)
         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:802)
    Can anyone please tell me the solution to this problem?
    thanks

    This post:
    http://mail-archives.apache.org/mod_mbox/jakarta-tomcat-user/200408.mbox/%[email protected]ys.com%3E
    Leads me to believe that you're compiling and targeting a java version that your tomcat installation doesn't support. What version of the JDK are you using?
    Good Luck
    Lee

  • Error when run a jsp page in tomcat

    I carefully follow all instruction to install and config j2sdk1.4.2 and Apache Tomcat/5.0.28. After completing, I can run all sample applications about JSP and Servlet in Tomcat manager. I also test my own servlet application and it also works.
    But I fail to run a very simple jsp page. Although I already set environment variables such as CATALINA_HOME, JAVA_HOME, CLASSPATH as directed but it seem to not be able to compile jsp page.
    ( I can compile other java classes in command line. )
    Below is the error i receive . This error takes me lots of time to consider.
    I look for your help ( please describe as clear as goog ). Thanks a lot.
    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
         org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:97)
         org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:346)
         org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:414)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:472)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:451)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:511)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:295)
         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:802)
    root cause
    Unable to find a javac compiler;
    com.sun.tools.javac.Main is not on the classpath.
    Perhaps JAVA_HOME does not point to the JDK
         org.apache.tools.ant.taskdefs.compilers.CompilerAdapterFactory.getCompiler(CompilerAdapterFactory.java:106)
         org.apache.tools.ant.taskdefs.Javac.compile(Javac.java:935)
         org.apache.tools.ant.taskdefs.Javac.execute(Javac.java:764)
         org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:382)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:472)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:451)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:511)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:295)
         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:802)

    If you are sure you've installed the JDK (as opposed to just a JRE, which doesn't come with the compilation tools that are required to compile JSPs), then your JAVA_HOME is probably set incorrectly. Ensure JAVA_HOME is pointing to the JDK directory, and not to the JRE directory.

  • Compile jsp page

    Hi,
    I hope someone could help me there is a point i haven't undeerstood!
    I want to print data from a base to a jsp.
    So i have created my driver and a bean to access my base.
    I compile my bean and the driver without any pbm(they belong to a package).
    But i can't compile my jsp page, impossible to find my package when compiling!!
    There is my so simple code:
    <%@ page language="java" import="Beandb.FieldBean" %>
    <jsp:useBean scope="page" id="FieldBean" class="Fieldbean" type="FieldBean" />
    <%
    String lang=request.getParameter("lang");
    System.out.println("language selected: "+lang);
    %>
    <%
    FieldBean.connect();
    Resultset RS = FieldBean.getResults(lang);
    if (RS != null)
    RS.next();
    %>
    <HTML>
    <head>
         <title>WELCOME ON SOUTH EUROPE INTRANET</TITLE>
    </head>
         <body>               
                   <%= RS.getDate(DATE_FIELD) %>
                   <%= RS.getString(TITLE_FIELD) %>
                   <%= RS.getString(CONTENT_FIELD) %>     
         </body>
    </HTML>
    <% } %>
    there are some of my error messages(3 only!!!):
    org.apache.jasper.JasperException: Unable to compile class for JSP
    An error occurred at line: 2 in the jsp file: /welcome/welcome.jsp
    Generated servlet error:
    [javac] Compiling 1 source file
    C:\Program Files\Apache Group\Tomcat 4.1\work\Standalone\localhost\hollister\welcome\welcome_jsp.java:43: cannot resolve symbol
    symbol : class FieldBean
    location: class org.apache.jsp.welcome_jsp
    FieldBean FieldBean = null;
    ^
    An error occurred at line: 2 in the jsp file: /welcome/welcome.jsp
    Generated servlet error:
    C:\Program Files\Apache Group\Tomcat 4.1\work\Standalone\localhost\hollister\welcome\welcome_jsp.java:45: cannot resolve symbol
    symbol : class FieldBean
    location: class org.apache.jsp.welcome_jsp
    FieldBean = (FieldBean) pageContext.getAttribute("FieldBean", PageContext.PAGE_SCOPE);
    ^
    An error occurred at line: 2 in the jsp file: /welcome/welcome.jsp
    Generated servlet error:
    C:\Program Files\Apache Group\Tomcat 4.1\work\Standalone\localhost\hollister\welcome\welcome_jsp.java:48: cannot resolve symbol
    symbol : class FieldBean
    location: class org.apache.jsp.welcome_jsp
    FieldBean = (FieldBean) java.beans.Beans.instantiate(this.getClass().getClassLoader(), "Fieldbean");
    ^

    I rename the id of the bean and change it too in my code.. But i still have a problem. Impossible to compile because of my package Beandb isn't find(message error: package Beandb does not exist.
    Whereas my Bean: FIeldBean belong to this package(i'm sure).
    I use tomcat, and there is my three:
    %hollisterpath%\welcome\welcome.jsp
    %hollisterpath%\WEB-INF\CLASSES\Beandb\FieldBean.class (compiled without any problem).
    I indicate in my classpath:
    %hollisterpath%\WEB-INF\CLASSES;%hollisterpath%\WEB-INF\CLASSES\Beandb;.\
    Does I have somewhere else to declare my package??
    Thanks for any response!!

  • Maximum size of a compiled JSP page

    Has anybody else come accross a problem with weblogic not displaying .jsp pages greater than
              

              One solution could be to break the jsps in small jsps ...
              "John" <[email protected]> wrote:
              >
              >Apparently there's a resitrction in the Java spec that the size of a
              >compiled method
              >cannot exceed 64kb. I'm looking for a way to get around this now
              >
              >Adam Willis <[email protected]> wrote:
              >>Has anybody else come accross a problem with weblogic not displaying
              >>.jsp pages greater than
              >
              

  • Cant find bean class from jsp page using Tomcat 4

    Hi
    I have searched numerpus forums and seen many posts from people who seem to have the same problem however none of the solutions seem to work for me.
    I have a jsp page which is trying to call a bean method however I get an error
    saying that the class for the bean cannot be found. I have :
    1. put the class in a package called kolaBean under
    C:\Program Files\Apache Tomcat 4.0\webapps\ROOT\begjsp-ch01\WEB-INF\classes\kolaPackage
    2. included the package statement in the java file for the bean
    3. included an empty constructor in the java file for the bean
    4. I have declared the above constructor as public (is this necessary?)
    5. used the full package name:
    kolaPackage.kolaBean bakedBean = new kolaPackage.kolaBean();
    6. imported import java.beans.*; (is this necessary ?)
    7. still got the same error...
    Any pointers really really appreciated
    Thanks
    Kola

    in reply to David Rons email:
    Is this a fresh install of tomcat? If so, it could be a configuration
    problem.Yes it is
    Is the class public in the package (I forget that all the time)?Yes it is. I have also declared the constructor to be public is this
    necessary?
    What's the error message?here is the error message:
    An error occurred between lines: 11 and 14 in the jsp file:
    /begjsp-ch01/kolaBean.jsp
    Generated servlet error:
    C:\Program Files\Apache Tomcat
    4.0\work\localhost\_\begjsp-ch01\kolaBean$jsp.java:59: Class
    kolaPackage.kolaBean not found.
         kolaPackage.kolaBean bakedBean = new
    kolaPackage.kolaBean();
         ^
    2 errors
    Thanks in advance
    Kola

  • Taglib repeating in jsp page in TOMCAT. (Can this be Tag pool issue? )

    Hi,
    We have an application and it is running fine on one servlet container "ServletExec". We are migrating our application to Tomcat and some weird things happenned.
    In one of my JSP pages say page " A ", I have included another small JSP say " B "which just created a table with one row and various columns.
    Now the columns are created in a taglib. And I am using that taglib inside that page " B".
    Now this is working fine in ServletExec.
    But in tomcat when I refersh page A or come to this page dfrom some other page, there are multiple instance of tables from page B are rendered.
    SO every time I refresh a new entry added to already existing table.
    Can any one please help?
    I looked in some documents and found that this may be because of some Tag pooling in Tomcat newer versions. Is that right?
    If yes how can I remove this tag pooling in my taglib java class?
    Any help is highly appreciated.
    Thanks

    Hi
    try disabling the tag pooling and check the page.
    To disable the tag pooling in Tomcat
    make enablePooling = false for the jsp servlet declaration in
    $TOMCAT_HOME/conf/web.xml
    Regards

  • Problem in compiling JSP page in OC4J 10.1.3.0.0

    Dear all,
    I started the ocj4 container that came with Jdeveloper. After starting the ocj4 server, I try to test it with the Servlet and JSP example. The Servlet Example work fine but I encounter the following error when I run the JSP example.
    2006-01-12 11:08:39.379 NOTIFICATION J2EE JSP0008 Unable to dispatch JSP Page :Exception:oracle.jsp.provider.JspCompileException: <H3>Errors compiling:C:\Program Files\Oracle\j2ee\home\application-deployments\default\defaultWebApp\persist
    ence\_pages\_examples\_jsp\_jsp2\_el\_basic_2d_arithmetic_2e_jsp.java</H3><pre><
    /pre>
    I think this should be a setup problem, please kndly advise.

    After reading the theads in the forum, I am able to get the jsp running by using full path to specify the java executable.
    e.g. C:\Program Files\Java\jdk1.5.0_02\bin\java -jar oc4j.jar
    This should be a path problem. After I set the path variable correctly
    i.e. add C:\Program Files\Java\jdk1.5.0_<version>\bin to PATH environment variable. It work fine. I hope this help the newbie like me. :D
    Indeed, I wonder why we need two jdk for the oc4j. Follow the instruction, I need to install a jdk. However, I find there is another jdk under $ORACLE_HOME\jdk. This is make the situation confusing and saw quite a lot of threads are related to this problem long time ago!

  • Compiling jsp pages in wl 10.0 2 times slower than wl 9.1

    Hi:
    I have enterprise application. In weblogic 9 it took 4-5min to compile all the jsp pages, in weblogic 10 it takes 10-11min!!
    Is there anything I can do to speed it up?

    Hi, thanks for your answers.
    Yes, I actually build the ear file and then I call weblogic.appc on it. And again, on wl 9 it used to take 4-5min, now it is taking 10-11min. Most of the time of the build process is taken by the page compilation.
    The other thing I noticed is that if I change a page the time it takes WL to recompile the page is way longer than before. I have to wait for a good 14-15seconds until the weblogic returns the new page. The weblogic java process goes up to almost 100%. Before, in WL 9 I had to wait just a few seconds. And ok, my computer is a dual core at 2.33GHz. Don't tell me I need to upgrade :-).
    I realize that the jsp compilation must have gotten more complicated because now jsf & jsp are unified but still....
    My app is a jsf application and I also use tag files.
    About precompiling the pages... I build the application on windows then I deploy it on linux. In WL 9, whenever I deployed the app, I had to precompile the pages otherwise the users experienced slower responses the first time. For whatever reason WL 9 didn't think the pages were already precompiled (they were part of the ear file). In WL 10 that seemed to have been fixed.

  • Warning - When Compiling .jsp pages under WEB-INF

    Created a directory jsp under WEB-INF and when i compile the jsp pages i get the following warning message
    Warning: package name web2d_inf._jsp does not match source file name C:\ProviderEnrollment\ProvEnrollView\classes\.jsps\_WEB_2d_INF\_jsp\_searchprovider.java
    Need help
    Thanks

    We have encountered this warning too.
    I'm not an Oracle employee, but it looks like there's a bug in JDev that preserves the case for the output directories but not for the package name that is supposed to correspond to the output directories.
    In any case, we haven't seen any runtime problems that seem to be related to this warning, so you may be safe to disregard it. It does foul up the build log though.
    Any JDev team members watching this topic are welcome to chime in with a confirmation and details of this apparent bug, as well as any workaround that might exist to avoid having the warning appear. Thanks!

  • My servlet cuts off the rest of my jsp page on Tomcat !

    I'm using the Oracle Jdevloper 9i to create a web application. I will then deploy the application to a Tomcat server. Now here is the problem. When developing and running on the Oracle OC4J server the application works fine but after deploying to the Tomcat, my included servlet cuts off the rest of my jsp page. The page runs fine and the first servlet gets executed. After the servlet there should be more jsp code, but after the execution the servlet the remaining jsp code simply disapears. Any Idea anyone ?

    A jsp page ending abruptly looks like a runtime error happening in the included servlet.
    Try commenting the line including the servlet.
    You may also want to check for errors in the servlet by invoking the servlet alone frm the browser.

  • Calling a class in JSP page using Tomcat 5.5

    Hi,
    I want to call a java class in a JSP page but getting error.
    I am trying to deploy JSP through a WAR file so for that I have created folder structure as per requirement and in WEB-INF folder, I kept web.xml file.
    What entry exactly I have to make in web.xml file as I am using Tomcat 5.5 webserver. When the same code I put in JSP then it works.
    my web.xml entry is
    <servlet>
    <servlet-name>TBS</servlet-name>
    <servlet-class>pack1.GetData</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>TBS</servlet-name>
    <url-pattern>/JSP/TBS_main</url-pattern>
    </servlet-mapping>
    Do I need to change in it or we have to make some more entries in different XML files.
    Please help me to resolve this issue.
    Thanks
    Mukesh

    you dont have to specify the class file in the web.xml just import it on your jsp then instatiate the class on the scriplet and you can call the methods on it.

  • ""." expected" error when compiling jsp page

    Hi all,
    I moved to develop all my applications from IBM WASD to JDeveloper but when I compile the projects in JDev, there's error ""." expected" for nearly all jsp pages. But these jsp pages for sure are working very well since almost of them are in production.
    Could you help me to get rid of this.
    Thanks in advance.

    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <%@page language = "java"
    contentType = "text/html"
    session = "true"
    autoFlush = "true"
    import = "java.util.*,java.sql.*,C_DBHandler"
    buffer = "4kb"
    isThreadSafe = "true"
    info = "Common File"
    %>
    <jsp:useBean id="hndQuery" scope="page" class="C_DBHandler" />
    <%
    // these are the application settings included in the pages where needed
    String txtQuery = ""; // SQL statement
    String ipaddress = "";
    String ipport = "";
    String virtualdir = "";
    String rowdisplay = "";
    hndQuery.doConnect((String)request.getAttribute("DB_DRIVER"),
    (String)request.getAttribute("URL_CONNECTION"),
    (String)request.getAttribute("CMN.USER_ID"),
    (String)request.getAttribute("CMN.USER_PASS"));
    txtQuery = "select ip_address, ip_port, virtual_dir, row_display from xserver_config where environment='Live' and application='M13000'";
    hndQuery.doSelect (txtQuery, 1);
    if (hndQuery.getRowCount() > 0)
    hndQuery.moveFirst ();
    ipaddress = hndQuery.getColumn("IP_ADDRESS");
    ipport = hndQuery.getColumn("IP_PORT");
    virtualdir = hndQuery.getColumn("VIRTUAL_DIR");
    rowdisplay = hndQuery.getColumn("ROW_DISPLAY");
    request.setAttribute("CE_SERVER", ipaddress+":"+ipport+"/"+virtualdir);
    request.setAttribute("ROW_DISPLAY", rowdisplay);
    hndQuery.doDisConnect();
         hndQuery.finalize();
    %><HTML>
    <HEAD>
    <META name="GENERATOR" content="IBM WebSphere Studio">
    </HEAD>
    </HTML>
    The jsp page is as above. And the error line is line 1. It 's always line 1 no matter what content of that line.

  • Appserver unable to Compile JSP pages

    Hello
    I have deployed a webapplication on SunONE application server installed on a SunOS 5.8 box. When I try to access any page , I keep getiing errors indicating that the page could not be compiled. An attempt to compile the page seperately using the javac installed with the App server however succeeds.
    The errors I get are as shown. The same webapp runs fine when installed on SunONE application server installed on Windows 2000 machine. Any help would be greatly appreciated
    org.apache.jasper.JasperException: Unable to compile class for JSPNote: sun.tools.javac.Main has been deprecated.
    An error occurred at line: 175 in the jsp file: /filesfolders/process_parameters.jsp
    Generated servlet error:
    /actu01/appserver7/appserv/instances/server1/generated/jsp/j2ee-modules/ap/_jasper/_filesfolders/_index_jsp.java:1962: Variable jbs may not have been initialized.
    bFilter = jbs.isDocChanFiltersEnabled();
    ^
    An error occurred between lines: 175 and 176 in the jsp file: /filesfolders/process_parameters.jsp
    Generated servlet error:
    /actu01/appserver7/appserv/instances/server1/generated/jsp/j2ee-modules/ap/_jasper/_filesfolders/_index_jsp.java:1970: Variable bFolders may not have been initialized.
    boolean bEmptyRS = !(bFolders || bExecutables || bDocuments);
    Thanks
    -Aniruddha

    I am having a similar problem on Windows 2000. Servlets run but jsp's all hit this error. Here is a copy of the log:
    [15/May/2003:07:40:16] INFO ( 1924): CORE1116: Sun ONE Application Server 7.0^M
    [15/May/2003:07:40:20] INFO ( 1924): CORE5076: Using [Java HotSpot(TM) Server VM
    , Version 1.4.1_01] from [Sun Microsystems Inc.]^M
    [15/May/2003:07:40:35] INFO ( 1924): JMS5023: JMS service successfully started.
    Instance Name = domain1_server1, Home = [C:\tools\as7se\imq\bin].^M
    [15/May/2003:07:40:40] INFO ( 1924): JTS5014: Recoverable JTS instance, serverId
    = [100]^M
    [15/May/2003:07:40:41] INFO ( 1924): RAR5060: Install JDBC Datasources ...^M
    [15/May/2003:07:40:41] INFO ( 1924): RAR5059: Binding [JDBC DataSource Name: jdb
    c/jdbc-simple, Pool Name: PointBasePool]^M
    [15/May/2003:07:40:42] INFO ( 1924): JMS5015: Install JMS resources ...^M
    [15/May/2003:07:40:44] INFO ( 1924): WEB0100: Loading web module [webapps-simple
    ] in virtual server [server1] at [webapps-simple]^M
    [15/May/2003:07:40:48] INFO ( 1924): HTTP3072: HTTP listener http-listener-1 [ht
    tp://LINDENBERGR-LT01:80] ready to accept requests^M
    [15/May/2003:07:40:48] INFO ( 1924): CORE3274: successful server startup^M
    [15/May/2003:07:40:48] INFO ( 1924): CORE5053: Application onReady complete.^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: java.lang.ClassFormatE
    rror: sun/tools/java/Parser (Illegal constant pool index)^M
    [15/May/2003:07:42:53] SEVERE ( 1924): StandardWrapperValve[jsp]: Servlet.servic
    e() for servlet jsp threw exception^M
    at com.iplanet.ias.web.jsp.JspServlet.serviceJspFile(JspServlet.java:322
    )^M
    at com.iplanet.ias.web.jsp.JspServlet.service(JspServlet.java:287)^M
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)^M
    at org.apache.catalina.core.StandardWrapperValve.invokeServletService(St
    andardWrapperValve.java:720)^M
    at org.apache.catalina.core.StandardWrapperValve.access$000(StandardWrap
    perValve.java:118)^M
    at org.apache.catalina.core.StandardWrapperValve$1.run(StandardWrapperVa
    lve.java:278)^M
    at java.security.AccessController.doPrivileged(Native Method)^M
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
    alve.java:274)^M
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
    a:505)^M
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
    alve.java:212)^M
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
    a:505)^M
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
    ava:203)^M
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
    a:505)^M
    at com.iplanet.ias.web.connector.nsapi.NSAPIProcessor.process(NSAPIProce
    ssor.java:157)^M
    at com.iplanet.ias.web.WebContainer.service(WebContainer.java:598)^M
    ^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.lang.Cla
    ssLoader.defineClass0(Native Method)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.lang.Cla
    ssLoader.defineClass(ClassLoader.java:502)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.security
    .SecureClassLoader.defineClass(SecureClassLoader.java:123)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.net.URLC
    lassLoader.defineClass(URLClassLoader.java:250)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.net.URLC
    lassLoader.access$100(URLClassLoader.java:54)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.net.URLC
    lassLoader$1.run(URLClassLoader.java:193)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.security
    .AccessController.doPrivileged(Native Method)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.net.URLC
    lassLoader.findClass(URLClassLoader.java:186)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.lang.Cla
    ssLoader.loadClass(ClassLoader.java:299)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at sun.misc.Laun
    cher$AppClassLoader.loadClass(Launcher.java:265)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.lang.Cla
    ssLoader.loadClass(ClassLoader.java:255)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.lang.Cla
    ssLoader.loadClassInternal(ClassLoader.java:315)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.lang.Cla
    ssLoader.defineClass0(Native Method)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.lang.Cla
    ssLoader.defineClass(ClassLoader.java:502)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.security
    .SecureClassLoader.defineClass(SecureClassLoader.java:123)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.net.URLC
    lassLoader.defineClass(URLClassLoader.java:250)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.net.URLC
    lassLoader.access$100(URLClassLoader.java:54)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.net.URLC
    lassLoader$1.run(URLClassLoader.java:193)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.security
    .AccessController.doPrivileged(Native Method)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.net.URLC
    lassLoader.findClass(URLClassLoader.java:186)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.lang.Cla
    ssLoader.loadClass(ClassLoader.java:299)^M
    @[15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at sun.misc.Laun
    cher$AppClassLoader.loadClass(Launcher.java:265)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.lang.Cla
    ssLoader.loadClass(ClassLoader.java:255)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at java.lang.Cla
    ssLoader.loadClassInternal(ClassLoader.java:315)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at sun.tools.jav
    ac.BatchEnvironment.parseFile(BatchEnvironment.java:453)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at sun.tools.jav
    ac.Main.compile(Main.java:486)^M
    [15/May/2003:07:42:53] WARNING ( 1924): CORE3283: stderr: at org.apache.ja
    sper.compiler.SunJavaCompiler$JavacTask.run(SunJavaCompiler.java:240)^M
    Thanks,
    Bob

  • Virtual Server fails to compile JSP pages -repeat

    I'm running iWS 6.0 SP2 using jdk 1.3
    I have 4 virtual servers defined each serving out HTML pages and everything runs fine.
    I'm building a 5th VS and I need it to support JSPs and nothing works...
    I've turned on all the debugging and trace features I can find but, nothing helps me resolve the fact
    that the JSPC can not locate the index.jsp file.
    Below is a copy of the JSP1x error found in the errors file:
    [12/Aug/2002:18:19:27] info (14254): Service(): uri=/index.jsp cgiScriptName=/index.jsp token=null cached=false
    [12/Aug/2002:18:19:27] info (14254): Internal Info: loading servlet /index.jsp
    [12/Aug/2002:18:19:27] info (14254): JSP: This is a jsp 1.x file
    [12/Aug/2002:18:19:27] info (14254): JSP: Before JSP1x compiler.compile, servletName = /index.jsp servletPath = /bto/appl/netserver/PROD/BUSINESSWARE/public_html/index.jsp & dir = ../ClassCacheclasspath = ../ClassCache
    [12/Aug/2002:18:19:27] info (14254): JSP11 Log:Package name is: _jsps
    [12/Aug/2002:18:19:27] info (14254): JSP11 Log:Class file name is: /bto/appl/iplanet/servers/https-TE-Production/config/../ClassCache/_jsps/_index_jsp.class
    [12/Aug/2002:18:19:27] info (14254): JSP11 Log:Java file name is: /bto/appl/iplanet/servers/https-TE-Production/config/../ClassCache/_jsps/_index_jsp.java
    [12/Aug/2002:18:19:27] info (14254): JSP11 Log:Class name is: indexjsp
    [12/Aug/2002:18:19:27] info (14254): JSP: JSP1x compiler threw exception
    java.io.FileNotFoundException: /bto/appl/netserver/PROD/MBDB/public_html/index.jsp
    at org.apache.jasper.compiler.JspReader.pushFile(JspReader.java:187)
    at org.apache.jasper.compiler.JspReader.<init>(JspReader.java:253)
    at org.apache.jasper.compiler.JspReader.createJspReader(JspReader.java:259)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:164)
    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:416)
    [12/Aug/2002:18:19:27] warning (14254): Internal error: Failed to get GenericServlet. (uri=/index.jsp,SCRIPT_NAME=/index.jsp)
    Based on the above information I notice a few things that seem to not follow the documentation.
    First the JSPC is looking for a file in MBDB/html even thought the original index.jsp file is
    part of the BUSINESSWARE virtual machine
    Second the ClassCache files do not follow the documented naming convention
    jsps/VS id/uriid ...
    Thanks in advance for your assistance.

    Not related to the problem but you shouldn't really be using JDK 1.3 (use JDK 1.3.1 if you need to use JDK 1.3+). As for the problem, the problem seems to be you don't seem to be ling web application. Could you add a web application with context root as "/" for the virtual server and I am positive this problem should go away.

Maybe you are looking for

  • Is it possible to make an alert message.

    Hi, Anyone knows if it Is possible to make an alert-message that pops up ( f.e as a little window) on a specific day to remember me of something I have to do that day? Would be handy. Is this possible with Tiger or is there a third party application

  • Comprehensive integration approach for photos across multiple computers?

    Hi All-- I've been wading through the discussion boards and have multiple partial pieces of info. However, I am looking for a state-of-the-art solution to an old problem because I want to integrate all of my photos onto a single drive and (probably)

  • Motion 3 wont open

    i upgraded to snow leopard last night and now motion gives me errors when it trys to open, HELP!!!! [email protected]

  • How do I change size of JComboBox's popup?

    I have a JComboBox. Problem is, I need the popup from this JComboBox to be wider than the JComboBox itself. How do I do this?

  • Help using a created type

    Anyone, I started by creating a typelike this: create type NUMS_TYP as object (nums number); That seemed to work fine. Now I'm trying to use that type in a PL/SQL procedure like this: FOR z IN (select empno from emp) LOOP IF z.empno IS OF (NUMS_TYP)