Joined: Sat May 02, 2009 7:30 am Posts: 1
|
Hi, I have a web application that is developed using webworks and hibernate (connection pooling c3p0 and 2nd level cache EHCache are enabled).
I this there is signing action which hits the database once to find if user exists or not.
for this i am using a query like "from UserDB where userID = :userID"
now when i try that with one user it takes around 1-2 sec to get back the response. and when a try with 1000 simultaneous actions it goes up till 9 seconds.
the execution sequence is 1. open a session (session factory is intitialized already) 2. create a query 3. execute 4. close the session in finally
In the logs it shows up as if queries are waiting. how could this be solved. c3p0 max connections are 20 and even "user" model is cached.
Please add to this thread if more information is required.
Dilip
|
|