tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jonathan Rengifo <jmreng...@gmail.com>
Subject Re: Problem upgrading to Tomcat 5
Date Mon, 06 Sep 2004 19:54:16 GMT
Sorry, I did it because don't know if this is a bug or something like
that, so I asked both...

I won´t do it again..


On Mon, 6 Sep 2004 20:50:51 +0100, Mark Thomas <markt@apache.org> wrote:
> 
> 
> Please do not cross-post. Questions like this should be asked solely on the user
> list, not on both lists.
> 
> Mark
> 
> > -----Original Message-----
> > From: Jonathan Rengifo [mailto:jmrengifo@gmail.com]
> > Sent: Monday, September 06, 2004 8:31 PM
> > To: tomcat-dev@jakarta.apache.org
> > Subject: Problem upgrading to Tomcat 5
> >
> > Hi all...
> >
> > I am preparing a new production web sever configured with Apache 2
> > serving static content and Tomcat 5.0.27 serving dynamic content via
> > TCP JK2 connector.
> >
> > In Tomcat, I am trying to configure one database Resource element for
> > various Context, so I decide to configure one Resource element into
> > the GlobalNamingResources element, and then  link it via ResourceLink
> > element on the Context I need to have; this configuration don´t work,
> > it throws me an exception on tomcat start up:
> >
> > java.lang.RuntimeException: com.MyCompany.db.ManagerException:
> > org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC driver
> > class 'oracle.jdbc.driver.OracleDriver'
> >
> > This happens although the driver is locate on my lib application, and
> > I try to cut an pasted on $TOMCAT_HOME/shared/lib and still get the
> > same output result.
> >
> > That configuration used to work on Tomcat 4, but don't know what
> > happened or change on new releases. I've read the "Server
> > Configuration Reference" documentation from
> > "http://manuals.thexdershome.com/tomcat-5.0/config/context.html" with
> > no success (There are examples using my server.xml configuration). So,
> > after all I just copy the Resource element on each Context and it
> > works, but believe this is not simple the best way to do this...
> >
> > Here is an example of what I've done:
> >
> > ....
> > ....
> >  <GlobalNamingResources>
> >
> > <Environment name="simpleValue" override="true"
> > type="java.lang.Integer" value="30"/>
> >
> > <Resource name="jdbc/app" auth="Container" scope="Shareable"
> > type="javax.sql.DataSource"/>
> >         <ResourceParams name="jdbc/app">
> >             <parameter>
> >                 <name>factory</name>
> >
> > <value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
> >             </parameter>
> >             <parameter>
> >                 <name>url</name>
> >
> > <value>jdbc:oracle:thin:@myDatabaseServer:port:user</value>
> >             </parameter>
> >             <parameter>
> >                 <name>password</name>
> >                 <value>myPassword</value>
> >             </parameter>
> >             <parameter>
> >                 <name>maxActive</name>
> >                 <value>20</value>
> >             </parameter>
> >             <parameter>
> >                 <name>maxWait</name>
> >                 <value>-1</value>
> >             </parameter>
> >             <parameter>
> >                 <name>driverClassName</name>
> >                 <value>oracle.jdbc.driver.OracleDriver</value>
> >             </parameter>
> >             <parameter>
> >                 <name>username</name>
> >                 <value>myUser</value>
> >             </parameter>
> >             <parameter>
> >                 <name>maxIdle</name>
> >                 <value>10</value>
> >             </parameter>
> >         </ResourceParams>
> > </GlobalNamingResources>
> >
> > ...
> > ...
> > ...
> >
> > <Host className="org.apache.catalina.core.StandardHost"
> >            appBase="webapps"
> >            autoDeploy="true"
> >            configClass="org.apache.catalina.startup.ContextConfig"
> >            contextClass="org.apache.catalina.core.StandardContext"
> >            debug="0"
> >            deployXML="true"
> >
> > errorReportValveClass="org.apache.catalina.valves.ErrorReportValve"
> >            liveDeploy="true"
> > mapperClass="org.apache.catalina.core.StandardHostMapper"
> >            name="mySubDomain.myDomain.com"
> >            unpackWARs="true">
> >
> >            <Valve
> > className="org.apache.catalina.valves.AccessLogValve"
> >                        pattern="combined"
> >                        resolveHosts="false"
> >                        directory="/appPath"/>
> >
> >
> >           <Context
> > className="org.apache.catalina.core.StandardContext"
> > cachingAllowed="true"
> >
> > charsetMapperClass="org.apache.catalina.util.CharsetMapper"
> > cookies="true"
> >                                         crossContext="false"
> >                                         debug="0"
> >                                         displayName="myApp"
> >                                         docBase="/appPath/root"
> >
> > mapperClass="org.apache.catalina.core.StandardContextMapper"
> >                                         path=""
> >                                         privileged="false"
> > reloadable="false" swallowOutput="false"
> >                                         useNaming="true"
> >
> > wrapperClass="org.apache.catalina.core.StandardWrapper"
> >                                         allowLinking="true">
> >
> >                             <ResourceLink name="jdbc/app"
> > global="jdbc/app" type="javax.sql.DataSource"/>
> >                         </Context>
> >             </Host>
> >
> > .....
> > .....
> > .....
> >
> > I was thinking too on move to Tomcat 5.0.28 relesed few days ago, to
> > see if problem solves, but don´t know what are the advantages and
> > bugfixes it has regarding 5.0.27 release I am using, can you please
> > tell me some or where to read them?
> >
> > Any help or comments you have would be very appreciated...
> >
> > Regards
> >
> > Jonathan
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org
> >
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org


Mime
View raw message