we are running a tomcat application using Hibernate to access to an mysql database and have the problem about the performance using it.
When enabling the hibernate_statistics it shows that database queries in average takes about 20 till 30 ms using hibernate. But the mysql-log shows that they only takes about 1 ms. Are 20 ms slow for hibernate; what are normal values?
And especially the method getRoles() (in Code 'Entitiy-Bean') takes about 50 ms when tracking the time in the code programmatly and hibernate do not log any database access for it. So what's wrong? The XML-Configuration for hibernate is attached too.
And maybe have someone any tips for improving the hibernate performance with tuning the hibernate properties shown below (code 'Hibernate and c3p0 (datasource) configurations')?
We are happy about any idea. Thanks.
Hibernate and c3p0 (datasource) configurations:
I promise I will be the best, most loyal friend ever! All for this tiny ad:
free, earth-friendly heat - a kickstarter for putting coin in your pocket while saving the earth