This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes JDBC and the fly likes connection pooling with firewall Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "connection pooling with firewall" Watch "connection pooling with firewall" New topic
Author

connection pooling with firewall

ajse ruku
Ranch Hand

Joined: May 06, 2005
Posts: 194
Hi all,
I have a firewall which closes all the connections which are idle for 30 mins.So i have included the following connection pooling parameters inside my context file.
timeBetweenEvictionRunsMillis=300000
numTestsPerEvictionRun=20
minEvictableIdleTimeMillis= 180000
I also have maxActive=50
maxIdle=100
maxWait=-1
But still its not working.Can anybody have any suggestion in this regard.

regards,
Ajse
Scott Selikoff
Saloon Keeper

Joined: Oct 23, 2005
Posts: 3704
    
    5

What server software are you using to manage the connection?


My Blog: Down Home Country Coding with Scott Selikoff
ajse ruku
Ranch Hand

Joined: May 06, 2005
Posts: 194
Hi,
I am using Tomcat 5.x and dbcp connection pooling.
regards,
Ajse
D Rog
Ranch Hand

Joined: Feb 07, 2004
Posts: 472

I think for most of connection pools you can setup lifetime of connection. So set it shorter than firewall setting and you should be safe. I use this approach with success.


Retire your iPod and start with HD Android music player Kamerton | Minimal J2EE container is here | Light weight full J2EE stack | and build tool | Co-author of "Windows programming in Turbo Pascal"
ajse ruku
Ranch Hand

Joined: May 06, 2005
Posts: 194
Hi,
Can you pls specify how can i set the life time of the connection i.e which parameter we need in this case?
regards,
ajse
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41599
    
  55
I'm curious: Is the firewall between the servers and the outside world, or is it between segments of the internal network? The former would imply that there's JDBC traffic coming in over the Internet - I'd be interested to hear what lead to that architectural choice. If the latter, where does the need for a firewall between internal systems come from?


Ping & DNS - my free Android networking tools app
ajse ruku
Ranch Hand

Joined: May 06, 2005
Posts: 194
Hi,

I dont have any control on these issues(firewall between internal servers).Probably this kind of settings can save the data in case of any hack.
But the problem is still there and not been fixed yet.
regards,
Ajse
D Rog
Ranch Hand

Joined: Feb 07, 2004
Posts: 472

Product companies always have problem like that. You can't dictate to customers how to configure firewall, otherwise they will get a product of your competitor which can manage such problems. I do not see lifetime for connection in your pool parameters. We used own pool and actually added this feature because met such requirements.
 
wood burning stoves
 
subject: connection pooling with firewall