commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From raj <rajsh...@yahoo.com>
Subject RE: DBCP POOL -Connection Pool giving nullpointer -->Unable to intialize -->Crashing
Date Wed, 05 May 2004 20:03:23 GMT
Hi Geeta,
Thanks for the help ful information. I close all my
connections in finally block. I did even try load
testing for 100 users in our testing environment and
did not see any issue.

BTW.. What do you mean by POOL size. Is this 
        connectionPool.setMaxActive(400);
parameter.

Let me know.
Thanks..Regards..RAJ

--- Geeta Ramani <gramani@terralink.com> wrote:
> Raj:
> 
> A *lot* of connection pool problems arise due to not
> returning connections to the pool properly (ie. in a
> finally block). I know you say that the code has not
> changed and therefore this cannot be the case, but
> carry out this experiment: Get the application
> working on a test machine - or your local machine -
> and and *set the pool size to 1*. Then test your
> application by clicking on various links and submit
> buttons and what not. You may very well come across
> a submit for which you wait indefintely. Look at the
> corresponding code - chances are either a statement
> is not closed, a result set is not closed, or (most
> likely) a connection is not closed in a **finally**
> block. In fact that may very well explain why you
> are having this problem all of a sudden: you may not
> have changed your code, but the data in the database
> may have changed - resulting in a query which does
> not succeed. So if your code closed the connection
> within the try block rather than in a finally block,
> then that connection may never be getting released.
> So when all the connections are "used up", you may
> well be having to wait indefintely.. Well, worth a
> shot anyways..:)
> 
> Regards,
> Geeta
> 
> > -----Original Message-----
> > From: raj [mailto:rajshiri@yahoo.com]
> > Sent: Wednesday, May 05, 2004 1:54 AM
> > To: Jakarta Commons Users List
> > Subject: DBCP POOL -Connection Pool giving
> nullpointer -->Unable to
> > intialize -->Crashing
> > 
> > 
> > Hello,
> > We have been using jakarta pool implementation
> with
> > JRUN for past 6 months and worked fine until last
> > week.
> > Started giving this error.
> > 
> > Works fine for couple of hours and starts crashing
> and
> > had to restart JRUN every time.
> > 
> > Explanation from our admin -->
> > Load on database causing delay in getting
> connection
> > from connection pool which is becoming stale after
> > trying to get connection for long time.
> > I did not like this explanation as nothing changed
> and
> > started suddenly.> 
> 
> 
>  
> > THANKS very much--
> > RAJ
> > 
> > > 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail:
> commons-user-help@jakarta.apache.org
> 



	
		
__________________________________
Do you Yahoo!?
Win a $20,000 Career Makeover at Yahoo! HotJobs  
http://hotjobs.sweepstakes.yahoo.com/careermakeover 

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message