tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Caroline Jen <jiapei_...@yahoo.com>
Subject RE: Server.xml configuration problem
Date Thu, 16 Sep 2004 19:46:27 GMT
Hi, yours is working now.  Mine is not.  I missed the
steps.  Could you post your server.xml file please? 
Thanks.
--- "LINGALA, AMARESHWAR G (SBCSI)" <al3495@sbc.com>
wrote:

> 
> It is working now, All I have to do is put the
> resource params inside of
> the <DefaultContext>
> 
>  Thanks for all your help !!!
>  
> 
> -----Original Message-----
> From: Jukka Uusisalo
> [mailto:jukka.uusisalo@dnainternet.net] 
> Sent: Thursday, September 16, 2004 1:50 PM
> To: Tomcat Users List
> Subject: Re: Server.xml configuration problem
> 
> 
> Hi,
> 
> Your datasource jdbc/myOracle must be inside some
> Context element or
> DefaultContext
> element like
> 
> <DefaultContext>
>   <Resource name="jdbc/myDataSource"
>                auth="Container"
>                type="javax.sql.DataSource"/>
> 
>   <ResourceParams name="jdbc/myDataSource">
>     <parameter>
>       <name>factory</name>n
>      
>
<value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
>     </parameter>
>     <!-- Add other resourceparams -->
> </DefaultContext>
> 
> Default context element is inside Host element. And
> also there have be
> reference in your
> application web.xml like
> 
>   <resource-ref>
>     <description>Datasource for my app</description>
>     <res-ref-name>jdbc/myDataSource</res-ref-name>
>     <res-type>javax.sql.DataSource</res-type>
>     <res-auth>container</res-auth>
>    </resource-ref>
> 
> - Jukka -
> 
> ----- Original Message ----- 
> From: "LINGALA, AMARESHWAR G (SBCSI)"
> <al3495@sbc.com>
> To: "Tomcat Users List"
> <tomcat-user@jakarta.apache.org>
> Sent: Thursday, September 16, 2004 9:21 PM
> Subject: RE: Server.xml configuration problem
> 
> 
> 
> Can you please be more specific, I tried to follow
> up the documents but
> am unable to fix the bug. Can you please send me the
> example of the
> change? I would be very much thankful to you.
> 
>  I am assuming that
> 
> <Resource name="jdbc/myoracle" auth="Container"
> >              type="javax.sql.DataSource"/>
> >
> > <ResourceParams name="jdbc/myoracle">
> 
>  Should make the tomcat recognise the database.
> 
>  Thanks
>   Amar
> 
> -----Original Message-----
> From: Shapira, Yoav [mailto:Yoav.Shapira@mpi.com]
> Sent: Thursday, September 16, 2004 1:12 PM
> To: Tomcat Users List
> Subject: RE: Server.xml configuration problem
> 
> 
> 
> Hi,
> You need to add an explicit Context element for your
> webapp, and inside
> it a ResourceLink element to make the
> GlobalNamingResources DataSource
> visible to your webapp.  Check the configuration
> reference document for
> GlobalNamingResourcs and ResourceLink for details.
> 
> Yoav Shapira
> Millennium Research Informatics
> 
> 
> >-----Original Message-----
> >From: LINGALA, AMARESHWAR G (SBCSI)
> [mailto:al3495@sbc.com]
> >Sent: Thursday, September 16, 2004 2:04 PM
> >To: Tomcat Users List
> >Subject: Server.xml configuration problem
> >
> >
> > Hi,
> >     I am trying to set-up Connection pooling for
> my web application, I
> >have made the following modifications to my
> server.xml file.
> >
> ><!-- Example Server Configuration File -->
> ><!-- Note that component elements are nested
> corresponding to their
> >     parent-child relationships with each other -->
> >
> ><!-- A "Server" is a singleton element that
> represents the entire JVM,
> >     which may contain one or more "Service"
> instances.  The Server
> >     listens for a shutdown command on the
> indicated port.
> >
> >     Note:  A "Server" is not itself a "Container",
> so you may not
> >     define subcomponents such as "Valves" or
> "Loggers" at this level.
> > -->
> >
> ><Server port="8005" shutdown="SHUTDOWN" debug="0">
> >
> >
> >  <!-- Comment these entries out to disable JMX
> MBeans support -->
> >  <!-- You may also configure custom components
> (e.g. Valves/Realms) by
> >       including your own mbean-descriptor file(s),
> and setting the
> >       "descriptors" attribute to point to a ';'
> seperated list of
> paths
> >       (in the ClassLoader sense) of files to add
> to the default list.
> >       e.g.
>
descriptors="/com/myfirm/mypackage/mbean-descriptor.xml"
> >  -->
> >  <Listener
>
>className="org.apache.catalina.mbeans.ServerLifecycleListener"
> >            debug="0"/>
> >  <Listener
>
>className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener"
> >            debug="0"/>
> >
> >  <!-- Global JNDI resources -->
> >  <GlobalNamingResources>
> >
> >    <!-- Test entry for demonstration purposes -->
> >    <Environment name="simpleValue"
> type="java.lang.Integer"
> >value="30"/>
> >
> >    <!-- Editable user database that can also be
> used by
> >         UserDatabaseRealm to authenticate users
> -->
> >    <Resource name="UserDatabase" auth="Container"
> >             
> type="org.apache.catalina.UserDatabase"
> >       description="User database that can be
> updated and saved">
> >    </Resource>
> >    <ResourceParams name="UserDatabase">
> >      <parameter>
> >        <name>factory</name>
> >
>
><value>org.apache.catalina.users.MemoryUserDatabaseFactory</value>
> >      </parameter>
> >      <parameter>
> >        <name>pathname</name>
> >        <value>conf/tomcat-users.xml</value>
> >      </parameter>
> >    </ResourceParams>
> >
> > <!--> Modified by Amar Lingala on 09/15/04 <-->
> > <Resource name="jdbc/myoracle" auth="Container"
> >              type="javax.sql.DataSource"/>
> >
> > <ResourceParams name="jdbc/myoracle">
> >   <parameter>
> >     <name>factory</name>
> >
>
><value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
> >   </parameter>
> >   <parameter>
> >     <name>driverClassName</name>
> >     <value>oracle.jdbc.driver.OracleDriver</value>
> >   </parameter>
> >   <parameter>
> 
=== message truncated ===



		
_______________________________
Do you Yahoo!?
Declare Yourself - Register online to vote today!
http://vote.yahoo.com

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


Mime
View raw message