Database Pooling


Connecting to Other Databases

Given all the configuration information we've presented in the last few sections, allowing an application to access databases besides MySQL using JNDI should be a snap. Here are the configurations for some other popular databases:

Oracle

 <database>   <jndi-name>jdbc/oracle</jndi-name>   <driver type="oracle.jdbc.pool. OracleConnectionPoolDataSource">   <url>jdbc:oracle:myschema:@localhost:product</url>   <user>username</user>   <password>password</password>   </driver> </database> 

Postgres

 <database>   <jndi-name>jdbc/mypostgre</jndi-name>   <driver type="org.postgresql.Driver">   <url>jdbc:postgres://localhost/product</url>   <user>username</user>   <password>password</password>   </driver> </database> 




Mastering Resin
Mastering Resin
ISBN: 0471431036
EAN: 2147483647
Year: 2002
Pages: 180

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net