Basic working server.xml for DBCP configuration

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Basic working server.xml for DBCP configuration

Pramodh Peddi
Hi,

 

Can anyone please give me your Tomcat's server.xml (of course with dummy
values for secure information) for a working DBCP configuration? I
basically need to know the xml structure of dbcp configuration under
Context element. I was using tomcat's documentation, but does not seem
to help. I am confused by Resource, ResourceParams, etc elements and not
knowing what exactly to use. I will really appreciate if any one can
provide me you working server.xml (relevant xml structure under Context
element).

 

Is it compulsory that this dbcp configuration NEEDS to be under Context
element? Can't it be right under Host element?

 

Thanks,

 

Pramodh.

Reply | Threaded
Open this post in threaded view
|

RE: Basic working server.xml for DBCP configuration

Pramodh Peddi
I think I am all set on this. This is the exact structure of relevant
xml, which worked for me:

 

...

...

<Host...>

<Context...>

<Resource name="jdbc/myDB"   auth="Container"
type="javax.sql.DataSource"/>

<ResourceParams name="jdbc/myDB">

<!- different connection and pooling related parameters -->

</ResourceParams>

      </Context>

<Host>

...

...

 

Thanks,

 

Pramodh.

 

-----Original Message-----
From: Pramodh Peddi
Sent: Wednesday, June 15, 2005 8:25 PM
To: [hidden email]
Subject: Basic working server.xml for DBCP configuration

 

Hi,

 

 

 

Can anyone please give me your Tomcat's server.xml (of course with dummy

values for secure information) for a working DBCP configuration? I

basically need to know the xml structure of dbcp configuration under

Context element. I was using tomcat's documentation, but does not seem

to help. I am confused by Resource, ResourceParams, etc elements and not

knowing what exactly to use. I will really appreciate if any one can

provide me you working server.xml (relevant xml structure under Context

element).

 

 

 

Is it compulsory that this dbcp configuration NEEDS to be under Context

element? Can't it be right under Host element?

 

 

 

Thanks,

 

 

 

Pramodh.

 

Reply | Threaded
Open this post in threaded view
|

Re: Basic working server.xml for DBCP configuration

Dirk Verbeeck
In reply to this post by Pramodh Peddi
Example configurations can be found on the DBCP wiki:
http://wiki.apache.org/jakarta-commons/DBCP
Feel free to add your own examples.

The reqources should be defined under Context. You can define them in
the global context and then refer to them in each specific host/context.

-- Dirk

Pramodh Peddi wrote:

> Hi,
>
>  
>
> Can anyone please give me your Tomcat's server.xml (of course with dummy
> values for secure information) for a working DBCP configuration? I
> basically need to know the xml structure of dbcp configuration under
> Context element. I was using tomcat's documentation, but does not seem
> to help. I am confused by Resource, ResourceParams, etc elements and not
> knowing what exactly to use. I will really appreciate if any one can
> provide me you working server.xml (relevant xml structure under Context
> element).
>
>  
>
> Is it compulsory that this dbcp configuration NEEDS to be under Context
> element? Can't it be right under Host element?
>
>  
>
> Thanks,
>
>  
>
> Pramodh.
>
>



---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]