I keep one connection per bolt and for now it works just fine with many bolts. I would also be interested in hearing from someone else and share experiences.
For now, I open the connection in the method prepare (and close it in cleanup), but to be completely honest, I'm not 100% sure if this is the best approach. cheers, Pablo. On Wed, Feb 19, 2014 at 4:41 PM, Brian O'Neill <[email protected]>wrote: > Yes. We use JDBI to access MySQL. > > We've had success with a shared connection pool. (one per JVM) > The bolts in the JVM share the pool. > > But either approach should work (pool per bolt, or connection per bolt). > It just depends at what level you want to manage your connections. > > We do it at the worker level. (n connections per worker) > > -brian > > --- > > Brian O'Neill > > Chief Technology Officer > > > *Health Market Science* > > *The Science of Better Results* > > 2700 Horizon Drive * King of Prussia, PA * 19406 > > M: 215.588.6024 * @boneill42 <http://www.twitter.com/boneill42> * > > healthmarketscience.com > > > This information transmitted in this email message is for the intended > recipient only and may contain confidential and/or privileged material. If > you received this email in error and are not the intended recipient, or the > person responsible to deliver it to the intended recipient, please contact > the sender at the email above and delete this email and any attachments and > destroy any copies thereof. Any review, retransmission, dissemination, > copying or other use of, or taking any action in reliance upon, this > information by persons or entities other than the intended recipient is > strictly prohibited. > > > > > From: Klausen Schaefersinho <[email protected]> > Reply-To: <[email protected]> > Date: Wednesday, February 19, 2014 at 5:58 AM > To: <[email protected]> > Subject: JDBC Connections > > Hi, > > one of my bolt will need to write to a MySql data base. Does anybody has > some experience with this? What are the best practices? Use an connection > pool? Or keep one connection open per bolt? > > Cheers, > > klaus >
