Ask the Expert

Using connection load balancing with Oracle RAC

When using XA data sources on a RAC database, the Oracle best practice is to set up a singleton service to avoid split branches. This limits the usefulness of RAC because we cannot load balance. Is it still safe to use connection load balancing? The data sources are defined in IBM WebSphere Application Server.

    Requires Free Membership to View

As you know, the problem with using load balancing at the Oracle level with WebSphere AS is that when a RAC instance fails, the WebSphere application may attempt to recover a transaction branch from the failing node and leave it hanging.

The setting up of singleton services forces single connections but you still need to point them to individual instances and use DTP to synchronize the transaction IDs.

The only way I know of to continue to use load balancing at the Oracle level is to catch the associated errors (ORA-01591 and/or ORA-24756) and rollback the in-doubt transactions with code.

The dba_2pc_pending view contains the pending transaction IDs.

I know this sounds messy but unless someone knows of a better workaround, this is the best I can come up with.

Good luck.

This was first published in July 2007

Join the conversationComment

Share
Comments

    Results

    Contribute to the conversation

    All fields are required. Comments will appear at the bottom of the article.