To setup an Oracle Datasource in Glassfish, follow these steps:
1. Copy the Oracle JDBC drivers to /glassfish/domains/domain1/lib/ext directory. You may need to change the directory /glassfish/domains/domain1 to match your installation of Glassfish and the domain name.
2. Start Glassfish.
3. Login to the admin interface and create a JDBC Connection Pool.
Delete all properties, and add following properties:
user - set this to Oracle userid
password - set this to Oracle password
URL - set this to the URL, example jdbc:oracle:thin:@localhost:1521:xe.
xa-driver-does-not-support-non-tx-operations - set this to true.
Test the connection pool using ping.
4. Create a JDBC DataSource using the Connection Pool.
3 comments:
Hi
I wrote an article about this, with a bit of information.
I hope this helps anyone to set it up quicker.
Here is the url:
http://www.jeveloper.com/docs/glassfish_oracle.html
or http://www.jeveloper.com/docs/glassfish_oracle.html
Worked with my Oracle 8i and 10g
Wow Great instructions, I was looking every where and finally found this site and fixed my issue in 2 mins! Thanks again
Another detailed tutorial for creating an oracle connection pool in Glassfisf (2.1.1) is here:
http://mariosgaee.blogspot.com/2009/12/oracle-connection-pool-in-glassfish.html
Post a Comment