tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From André Warnier ...@ice-sa.com>
Subject Re: Tomcat jdbc pool connection failover
Date Mon, 11 Mar 2013 15:00:07 GMT
Hi.
Don't "top post".

amit shah wrote:
> Apparently we use Oracle as our data store while the solution you mentioned
> is for mysql.

And did you check if the Oracle JDBC driver provides such an option ?

> 
> Is there a way tomcat can provide a notification after all its retries to
> the database server have failed? This way at least I can create a new
> connection pool configured to a different database server in order to
> simulate a automatic connection failover from the application side. I
> understand that this step would require time for the retries and creation
> of new pool.

I am not a Java specialist, but I would imagine that at least your application would get 
some kind of I/O exception when that happens on a read or a write.
Can you not catch that and do whatever you need to then ?
After all, even if the driver itself handles the primary case, there would still be a 
possibility that even your backup database server would also be unreachable, no ?

> 
> Thanks.
> 
> 
> On Mon, Mar 11, 2013 at 6:15 PM, Daniel Mikusa <dmikusa@vmware.com> wrote:
> 
>> On Mar 11, 2013, at 12:52 AM, amit shah wrote:
>>
>>> Hello,
>>>        I would like to know if the tomcat jdbc pool (7.0.34+) provides
>>> connection failover capabilities i.e. to transparently close all the open
>>> database connections and switch to a another database server on an
>>> planned/unplanned database server outage event.
>>>        I read through the tomcat documentation but didn't find any
>> details
>>> related to this. If this feature is not supported are there any
>> recommended
>>> alternatives and any future plans to add this feature to the jdbc pool?
>> You might want to see if your JDBC driver will handle this for you.  I
>> know that some do, like MySQL [1].
>>
>> Dan
>>
>> [1] -
>> https://dev.mysql.com/doc/refman/5.1/en/connector-j-reference-configuration-properties.html
>>
>>> Thank you,
>>> Amit
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message