[jboss-user] [Performance Tuning] - Re: Slow remote database connection

otaylor do-not-reply at jboss.com
Mon Nov 13 11:13:27 EST 2006

What I'd suggest doing is increasing the verbosity of logging from Hibernate
to the point you can get it to log the SQL queries it is doing in check to make
sure that the *number* of queries it is doing is reasonable. One possible reason
that a large query might be slow remotely is that it is doing one query to
fetch the set of rows and then an addititional query per-row. The per-query
latency will be greater with a remote database, and even a millisecond or
two per row can add up to a lot.

(If you do find thousands of queries, it may be that some relationships on your entities 
need to be made lazy)

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3985492#3985492

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3985492

More information about the jboss-user mailing list