users@glassfish.java.net

Glassfish 2.1 and connection pool config for Oracle RAC

From: <forums_at_java.net>
Date: Thu, 11 Aug 2011 02:23:03 -0500 (CDT)

Hi

Like some others who have posted on these forums my experience to date has
been mostly Apache/MySQL, so I'm a little bogged down with this one.

Has anyone got clear instructions for connecting a GF domain to Oracle RAC
using the FastConnectioFailOver mechanism?

What’s supposed to happen is that the App server connects to RAC at
startup, in turn RAC sends messages back to the application via ONS in the
event of any service failure, then the application can clear its connection
pool immediately without incurring timeouts.

I have been given the following parameters:

ONS_CONFIG =
"nodes=rac1-vip.example.com:6200,punter-rac2-vip.example.com:6200,punter-rac3-vip.example.com:6200";

ConnectionFactoryClassName("oracle.jdbc.pool.OracleDataSource");
InactiveConnectionTimeout(120);
ConnectionWaitTimeout(20);
PropertyCycle(60);
FastConnectionFailoverEnabled(true);
ONSConfiguration(ONS_CONFIG);

URL: jdbc:oracle:thin:@//rac-scan.example.com/domain1.example.com

Drivers ojdbc6.jar, ons.jar and ucp.jar have been copied to the
$GLASSFISH_HOME/<domain>/lib dir and I can confirm from strace that these
libraries are being opened when the domain starts.

ONS_CONFIG =
"nodes=rac1-vip.example.com:6200,punter-rac2-vip.example.com:6200,punter-rac3-vip.example.com:6200";

I created a new connection pool called RAC_Test_Pool and putting the
configuration items supplied by Ilmar into the advanced properties, and
pointed b2DataSource and b2TXDataSource at that. I’ve installed the drivers
in the lib directory, and we are making connections to the RAC. Problem is,
there are no connections being made to the RAC on port 6200 at any time, and
there is no traffic on that port at any point. The remote servers/ports are
reachable, so no firewall issues.

Any help greatly appreciated.

TiA

 


--
[Message sent by forum member 'hackinjack']
View Post: http://forums.java.net/node/831333