tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Johann Uhrmann <johann.uhrm...@xpecto.com>
Subject DefaultContext vs Context
Date Mon, 07 Oct 2002 11:34:52 GMT
Hi,

is there a known problem / bug with defining resources in the
DefaultContext?

The following resource definition works in a Context-environment
but won't be inherited from the DefaultContext to contexts automatically
created by tomcat for war-files (and for the ant-target "deploy"):


 <Resource auth="Container" name="jdbc/sms" scope="Sharable"
type="javax.sql.DataSource"/>
          <ResourceParams name="jdbc/sms">
            <parameter>
              <name>url</name>
              <value>jdbc:postgresql://dbserver:5432/foo</value>
            </parameter>
            <parameter>
              <name>validationQuery</name>
              <value>select name from users</value>
            </parameter>
            <parameter>
              <name>maxIdle</name>
              <value>10</value>
            </parameter>
            <parameter>
              <name>maxActive</name>
              <value>20</value>
            </parameter>
            <parameter>
              <name>driverClassName</name>
              <value>org.postgresql.Driver</value>
            </parameter>
            <parameter>
              <name>maxWait</name>
              <value>-1</value>
            </parameter>
            <parameter>
              <name>username</name>
              <value>foo</value>
            </parameter>
            <parameter>
              <name>factory</name>
             
<value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
            </parameter>
            <parameter>
              <name>password</name>
              <value>bar</value>
            </parameter>
          </ResourceParams>

Is there anything more to do than moving this definition from Context
to DefaultContext in order to make the resource available for all
web applications?

Thank You in advance,

Hans


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


Mime
View raw message