Home » Server Options » Data Guard » Client connections slow in failover situation
Client connections slow in failover situation [message #648497] Wed, 24 February 2016 03:37 Go to previous message
ToomasAas
Messages: 4
Registered: October 2015
Junior Member
We have Data Guard set up with Oracle 12c. Failover itself works fine, but there is a problem when connecting from Java application to database in failover situation (when primary server is down).

This is perhaps a problem in a way the underlying networking is set up (which is not under our control). When primary server is down, TCP connection attempts from application server to the primary database do not fail immediately with "no route to host" or similar error. Instead, connection attempts stall for 60 seconds and then fail with "connection timed out".

I added TRANSPORT_CONNECT_TIMEOUT=2 and CONNECT_TIMEOUT=3 in connection string of our Java application. This helps somewhat, but still it seems that every request from application to database is subject to this 3-second timeout so there is a noticeable performance impact.

Is there anything else I can do on application or Oracle side before I point the finger at network team?

For reference, here is the entire connection string:

ctx.appDataSource.url=jdbc:oracle:thin:@(DESCRIPTION=(LOAD_BALANCE=no)(FAILOVER=yes)(ADDRESS=(PROTOCOL=TCP)(HOST=Db01)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=DG))(ADDRESS=(PROTOCOL=TCP)(HOST=Db02)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=DG))(FAILOVER_MODE=(type=select)(method=preconnect)(retries=180)(delay=10))(TRANSPORT_CONNECT_TIMEOUT=2)(CONNECT_TIMEOUT=3))


P.S. I also tried TYPE=SESSION and METHOD=BASIC, but this didn't seem to make any difference.
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Archive log shipping not happening between Primary and Standby
Next Topic: no output from v$archived_log in standby
Goto Forum:
  


Current Time: Fri Jan 24 01:51:07 CST 2020