tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "charly" <charly41...@yahoo.de>
Subject Re: Upgrade problem (useBean)
Date Sat, 19 Aug 2006 12:25:03 GMT
Is this issue still current?

If yes I have seen more emails on the list about such problems and
it  was because a configuration error:
In TC 5.5.17 you will have troubles when

<host appBase="path" ..>  and <context docBase="path" ..>
having  identical paths or the context docBase attribute ist empty:
<context docBase="".. >
which also means that the paths are identical.

Use different paths oder at least set <host autoDeploy="false"

> <Host name="192.168.1.231" 
> appBase="/opt/apache-tomcat-5.5.17/webapps/application1" unpackWARs="true" 
> autoDeploy="true" xmlValidation="false" xmlNamespaceAware="false">
>    <Context path="/" debug="0" 
> docBase="/opt/apache-tomcat-5.5.17/webapps/application1" reloadable="true">
>        <ResourceLink global="PSQLAPPLICATION1" name="jdbc/application1" 
> type="javax.sql.DataSource" />
>    </Context>


HTH

Karl-Heinz




----- Original Message ----- 
From: "Lars Nielsen Lind" <soa@tidtilforandring.dk>
To: "Tomcat Users List" <users@tomcat.apache.org>
Sent: Tuesday, August 08, 2006 9:12 AM
Subject: Re: Upgrade problem (useBean)


> Mark Thomas skrev:
>> Lars Nielsen Lind wrote:
>>
>>
>>> All my webapps and contents (including WEB-INF and components) are
>>> copied from an existing running solution with no problems.
>>>
>>> Anyone that know how to solve this?
>>>
>>
>> Is there a more complete stack trace and/or exception in the logs?
>>
>> Mark
>>
>> ---------------------------------------------------------------------
>> To start a new topic, e-mail: users@tomcat.apache.org
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
>>
> Yes, but first this addidtional info.
>
> I am using Fedora Core 5 OS and as mentioned above I have tried with:
>
> apache-2.2.2/tomcat-5.5.17
> apache-2.2.3/tomcat-5.5.17
> apache-2.0.59/tomcat-5.5.17
>
> Finally I have copied the whole /opt/apache-2.0.54 and /opt/tomcat-5.5.9 from 
> my backups and when running them with the same webapps as in the setups 
> mentioned above it all works the way it should.
>
> When I am running apache-2.2.2/tomcat-5.5.17 I do not get any error when 
> showing index.jsp. But when I use the same bean in subfolders in 
> webapplication:
>
> /opt/tomcat-5.5.17/webapps/application1   index.jsp   OK
> /opt/tomcat-5.5.17/webapps/application1/contact/   contactform.jsp   ERROR
>
> I get an error. I have tried to change name and after searching the net one 
> mentioned that it is a missing default constructor in my javabean that is the 
> problem (I have default constructors in my beans) anothe mentioned to shift 
> <useBean class="xx.yy.zz" ... /> with <useBean type="xx.yy.zz" ... />. It
did 
> not solve the problem shifting form class to type.
>
> Here is the error-report shown in the browser:
>
> *type* Exception report
>
> *message*
>
> *description* _The server encountered an internal error () that prevented it 
> from fulfilling this request._
>
> *exception*
>
> org.apache.jasper.JasperException: /index.jsp(5,0) The value for the useBean 
> class attribute internet.database.SimpleUseOfConnectionPool is invalid.
> org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:510)
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:375)
> 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*
>
> org.apache.jasper.JasperException: /index.jsp(5,0) The value for the useBean 
> class attribute internet.database.SimpleUseOfConnectionPool is invalid.
> org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:39)
> org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:405)
> org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:146)
> org.apache.jasper.compiler.Generator$GenerateVisitor.visit(Generator.java:1174)
> 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:3305)
> org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:198)
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:303)
> 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)
>
> *note* _The full stack trace of the root cause is available in the Apache 
> Tomcat/5.5.17 logs._
>
>
>
> And here is the output from tomcat-logs:
>
> 2006-08-08 08:51:45 org.apache.catalina.core.StandardWrapperValve invoke
> SEVERE: Servlet.service() for servlet jsp threw exception
> org.apache.jasper.JasperException: /index.jsp(5,0) The value for the useBean 
> class attribute internet.database.SimpleUseOfConnectionPool is invalid.
>    at 
> org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:39)
>    at 
> org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:405)
>    at 
> org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:146)
>    at 
> org.apache.jasper.compiler.Generator$GenerateVisitor.visit(Generator.java:1174)
>    at org.apache.jasper.compiler.Node$UseBean.accept(Node.java:1116)
>    at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
>    at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2213)
>    at org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2219)
>    at org.apache.jasper.compiler.Node$Root.accept(Node.java:456)
>    at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
>    at org.apache.jasper.compiler.Generator.generate(Generator.java:3305)
>    at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:198)
>    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
>    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
>    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
>    at 
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
>    at 
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:303)
>    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
>    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
>    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
>    at 
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
>    at 
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
>    at 
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>    at 
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
>    at 
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
>    at 
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
>    at 
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
>    at 
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
>    at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:199)
>    at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:282)
>    at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:754)
>    at 
> org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:684)
>    at 
> org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:876)
>    at 
> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
>    at java.lang.Thread.run(Thread.java:595)
>
> Here is my httpd.conf (part of it):
>
> <IfModule mod_jk.c>
>
> JkWorkersFile conf/workers.properties
>
> JkLogFile        /opt/apache-2.2.2/logs/mod_jk.log
> JkLogLevel        info
> JkLogStampFormat    "[%a %b %d %H:%M:%S %Y] "
> JkRequestLogFormat    "%w %V %T"
>
> JkOptions        +ForwardKeySize +ForwardURICompat +ForwardDirectories
>
>        JkMount        /*.jsp default
>        JkMount        /servlet/* default
>        JkMount        /cewolf/* default
>        JkMount        /*.png default
> </IfModule>
>
> <VirtualHost 192.168.1.231:80>
>    ServerName 192.168.1.231
>
>    DocumentRoot /opt/apache-tomcat-5.5.17/webapps/application1
>
>    <Directory />
>        Options FollowSymLinks
>        AllowOverride None
>    </Directory>
>
>    <Directory "/opt/apache-tomcat-5.5.17/webapps/application1">
>        Options -Indexes Includes FollowSymLinks
>        AllowOverride None
>        Order allow,deny
>        Allow from all
>    </Directory>
>
>    <Location /WEB-INF>
>        AllowOverride None
>        Deny from all
>    </Location>
>
>    DirectoryIndex index.html index.jsp
> </VirtualHost>
>
>
>
> Here is my workers.properties:
>
> workers.tomcat_home=/opt/apache-tomcat-5.5.17
> workers.java_home=/opt/jdk1.5.0_07
> ps=/
>
> worker.list=default
>
> worker.default.type=ajp13
> worker.default.host=localhost
> worker.default.port=8009
>
> worker.default.cachesize=10
> worker.default.cache_timeout=600
> worker.default.socket_keepalive=1
> worker.default.reclycle_timeout=300
>
>
> Here is my server.xml (part of it):
>
> <Host name="192.168.1.231" 
> appBase="/opt/apache-tomcat-5.5.17/webapps/application1" unpackWARs="true" 
> autoDeploy="true" xmlValidation="false" xmlNamespaceAware="false">
>    <Context path="/" debug="0" 
> docBase="/opt/apache-tomcat-5.5.17/webapps/application1" reloadable="true">
>        <ResourceLink global="PSQLAPPLICATION1" name="jdbc/application1" 
> type="javax.sql.DataSource" />
>    </Context>
>      </Host>
>
>
> Here is the web.xml for application1 in WEB-INF:
>
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <web-app xmlns="http://java.sun.com/xml/ns/j2ee"
>    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee 
> http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
>    version="2.4">
>
>    <resource-ref>
>        <description>PostgreSQL DataSource</description>
>        <res-ref-name>jdbc/application1</res-ref-name>
>        <res-type>javax.sql.DataSource</res-type>
>        <res-auth>Container</res-auth>
>    </resource-ref>
> </web-app>
>
>
> Here is the context.xml for application1 in META-INF:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <Context path="/application1"/>
>
>
>
>
> Lars Nielsen Lind
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 


	

	
		
___________________________________________________________ 
Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message