I'm developing high load web service that would provide as faster response as possible. Service should keep a bunch of connections to various databases for faster performance. I'm suggesting using connection pool for that. There's may be connection problems to DB because we have a lot of remote DB accessing through VPN. As I said service should have connection as long as it possible.
What is the connection pool management algorithm?
I have a connection string:
Code: Select all
User Id=inet;Password=somePassw0rd;Data Source=TEST11;Min Pool Size=5;Max Pool Size=15;Pooling=True
Then I simply open and close connection in my code. That's it. At this moment everything is OK. There are five sessions on DB side. Then I kill one session imitating connection problems. And in some cases connection will be restored by pool manager and in some cases it won't.
If I kill all five connections they are never won't restored back.
How can I confiure pooling manager? Any settings for duration between checks DB connections?
I have used "validate connection=true;" it seems to work fine for me, but it needs some efforts to reconnect to DB again and it would be more efficiently to have already good connection.
Thanks in advance!