tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Gainty <mgai...@hotmail.com>
Subject RE: DBCP and Firewall timeouts
Date Wed, 08 Jul 2009 01:47:18 GMT

i vote against 2 different connection pools
thats 2 configurations placing twice the load routing to the same DB not a good long term
situation 

a more viable option is to port your RAILS code to GRAILS and all others Struts/JSF/Axis to
use the same DBCP which would be configured within server.xml GlobalNamingResources

the other option is to enforce all connections to be acquired thru some XA Transaction Management..XA
would funnel all requests to a common connection pool via a TransactionManager..this is a
big deal to configure as it can take connection requests from multiple servers..as this is
oracle specific.. feel free to ping me offline for details 
http://download.oracle.com/docs/cd/B10501_01/appdev.920/a96590/adga1_xa.htm

you will also want to up the number of connections from 8 allowed by DBCP to accomodate
as seen here
http://people.apache.org/~dirkv/dbcp/configuration.html

as previously mentioned you want to place your config into GlobalNamingResources
http://tomcat.apache.org/tomcat-5.5-doc/config/globalresources.html
so all applications would be using the same DBCP configuration and same connection pool

Martin Gainty 
______________________________________________ 
Jogi és Bizalmassági kinyilatkoztatás/Verzicht und Vertraulichkeitanmerkung/Note de déni
et de confidentialité
 Ez az
üzenet bizalmas.  Ha nem ön az akinek szánva volt, akkor kérjük, hogy
jelentse azt nekünk vissza. Semmiféle továbbítása vagy másolatának
készítése nem megengedett.  Ez az üzenet csak ismeret cserét szolgál és
semmiféle jogi alkalmazhatósága sincs.  Mivel az electronikus üzenetek
könnyen megváltoztathatóak, ezért minket semmi felelöség nem terhelhet
ezen üzenet tartalma miatt.

Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger sein, so bitten
wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung oder Fertigung einer Kopie ist
unzulaessig. Diese Nachricht dient lediglich dem Austausch von Informationen und entfaltet
keine rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von E-Mails koennen
wir keine Haftung fuer den Inhalt uebernehmen.
Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le destinataire
prévu, nous te demandons avec bonté que pour satisfaire informez l'expéditeur. N'importe
quelle diffusion non autorisée ou la copie de ceci est interdite. Ce message sert à l'information
seulement et n'aura pas n'importe quel effet légalement obligatoire. Étant donné que les
email peuvent facilement être sujets à la manipulation, nous ne pouvons accepter aucune
responsabilité pour le contenu fourni.




> Date: Tue, 7 Jul 2009 12:31:53 -0400
> Subject: Re: DBCP and Firewall timeouts
> From: straightflush@gmail.com
> To: users@tomcat.apache.org
> 
> we are using Jruby / Rails / Tomcat.  I think what may be happening is
> that rails has its own connection pool in front of DBCP which could be
> causing the issue here, not sure yet.
> 
> AD
> 
> On Tue, Jul 7, 2009 at 12:20 PM, David Smith<dns4@cornell.edu> wrote:
> > Do you hold on to your connections in code or do you close them when
> > done with each request?  If you hold on to them, they can still timeout
> > with or without a validationQuery set.
> >
> > --David
> >
> > AD wrote:
> >> unfortunately still not working.  One thing that i noticed, when i
> >> clear my browser cookies, everything works fine again.  One of the
> >> things we do is use cookie persistence to send a user to the same
> >> tomcat server (we need this for file uploads,etc).  Is there anything
> >> in the session cookie that would cause this issue?
> >>
> >> Thanks
> >> AD
> >>
> >> On Thu, Jul 2, 2009 at 9:38 AM, Christopher
> >> Schultz<chris@christopherschultz.net> wrote:
> >> David,
> >>
> >> On 7/1/2009 5:01 PM, David Smith wrote:
> >> >>> Christopher Schultz wrote:
> >> >>>> David,
> >> >>>>
> >> >>>> On 7/1/2009 10:49 AM, David Smith wrote:
> >> >>>>> It would and the performance hit is minimal if you use
the ping
> >> syntax
> >> >>>>> in your validation query.  I believe it looks like this:
> >> >>>>> validationQuery="/* ping */ SELECT 1"
> >> >>>> Note that both the PING is only applicable for MySQL when using
> >> >>>> Connector/J, and "SELECT 1" may only be applicable on certain
> >> databases
> >> >>>> (MySQL being one of them).
> >> >>>>
> >> >>> Right and I double checked the original post that started this
thread.
> >> >>> AD described the environment as having MySQL 5.1
> >> Apologies... the thread was broken somewhere along the way and the
> >> original message wasn't grouped with the others in my mail reader. The
> >> OP definitely said they were using MySQL 5.1.
> >>
> >> -chris
> >
> >
> > ---------------------------------------------------------------------
> > 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
> 

_________________________________________________________________
Hotmail® has ever-growing storage! Don’t worry about storage limits. 
http://windowslive.com/Tutorial/Hotmail/Storage?ocid=TXT_TAGLM_WL_HM_Tutorial_Storage_062009
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message