ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Clinton Begin" <clinton.be...@gmail.com>
Subject Re: Performance issue when using Glassfish
Date Wed, 18 Jun 2008 20:33:16 GMT
Couple of things here....

1) I belive the ResultSet line is printed after all of the results are
finished being read.  Even if that's not the case line-for-line with iBATIS,
it's possible the driver is actually prefetching a group of records upon the
first access of he result set.

2) Using iBATIS logging for performance benchmarking is a bad idea.  iBATIS
logging is very resource intensive and is only intended for debugging.  It
should be shut off in production and during performance testing.

I recommend a proper profiling tool that will let you introspect deeper into
your application.  I belive there are free profilers for both Eclipse and


On Wed, Jun 18, 2008 at 2:23 PM, <Christopher.Mathrusse@sybase.com> wrote:

> I'm running iBatis within Spring 2.5 inside of Glassfish.
> (Actually, I was running inside of Tomcat without any issues) We are
> migrating to Glassfish and the only change I've made is to utilize the
> resources from Glassfish, via JNDI. This includes the TX Manager as well as
> all DataSources. Should be not problem and no issues but I seem to be
> hitting a performance issue down deep in iBatis. I see the initial hit on
> the Dao, and I can see the Prepared Statement being generated. No issues
> there. I see the values that are bound to the statement and I can see it
> getting executed. (I intercept all the jTDS calls to the Sybase ASE so I can
> line up invocation timestamps) But it seems from the time that iBatis is
> executing the SQL to the time that it is reading the results that something
> is happening that is consuming a great deal of time.
> *TDS interception shows:*
> [2008-06-18 13:06:21.145] Thread-11: Client->Server: read 400 from client.
> Writing...
> [2008-06-18 13:06:40.319] Thread-11: Client->Server: read 187 from client.
> Writing...
> As you can see over 18 seconds went somewhere.
> *From the log4j logging:*
> 2008-06-18 13:06:21,082 [httpSSLWorkerThread-8080-1 : ]
> [DEBUG,PreparedStatement] {pstm-100010} Types: [java.lang.Integer,
> java.lang.Integer]
> 2008-06-18 13:06:40,303 [httpSSLWorkerThread-8080-1 : ] [DEBUG,ResultSet ]
> {rset-100011} ResultSet
> Same as above, 18+ seconds went somewhere.
> I can't seem to get the logging in ibatis to work. I've added it to my
> log4j configuration but for some reason nothing is printed out from iBatis.
> (Spring dumps well though so I can get some idea about what is happening)
> I know that this is an extremely odd issue but I was hoping that someone
> may have seen something like this prior.
> Thanks for the help...
> Chris

View raw message