ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Glezen <pgle...@us.ibm.com>
Subject RE: iBatis logging
Date Wed, 31 Aug 2005 18:11:33 GMT




I was hoping to see some output from whatever implements SqlMapClient.  For
example, I'm seeing the following based on tracing from an Oracle JDBC
driver,

1. I sandwhich a read-only query between sqlMap.startTransaction() and
sqlMap.commitTransaction.  But I see no commit issued to the driver, and
indeed, my WebSphere application server groans about having to clean up
unresolved transactions at the end of an LTC boundary (effectively, the end
of a method).

2. I see autocommit set to false (not sure why this happens), and yet
commits being issued after each update in a sequence of two updates (don't
know where these come from).  I'd like to investigate what is invoking
commit each time in the absence of using the iBatis transaction API.  (When
I use the iBatis transaction API to scope the transactions across the
updates, it works fine.)

So I'm hoping there is some trace I can enable to inform me when iBatis is
driving commits, or setting autocommit modes.  Right now, I can only see
that they have occurred through the driver tracing, but not what is driving
them.

- Paul



"Niels Beekman" <n.beekman@wis.nl> wrote on 08/31/2005 10:50:58 AM:

> Hi,
>
> The java.sql.*-outputs are from iBATIS too, java.sql does not do any
> debugging on it’s own… What logging did you expect?
>
> Niels
>
>
> From: Paul Glezen [mailto:pglezen@us.ibm.com]
> Sent: woensdag 31 augustus 2005 18:16
> To: user-java@ibatis.apache.org
> Subject: iBatis logging
>
> Hi Folks,
>
> I'm having a some trouble with iBatis logging.  My log4j.properties
> looks like this for my JUnit tests:
>
> ---------------- log4j.properties --------------------
> log4j.rootLogger=DEBUG,stdout
>
> log4j.appender.stdout=org.apache.log4j.ConsoleAppender
> log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
> log4j.appender.stdout.layout.ConversionPattern=%d{HH:mm:ss:SSS} %5p
> %c{5} - %m%n
> ---------------- log4j.properties
>
> But the only iBatis class I see logging anything is the
> SimpleDataSource class.  Here is a sample of what I'm seeing (with
> sensitive customer info removed):
>
> 09:06:18:208 DEBUG java.sql.PreparedStatement - {pstm-100011} Types:
> [java.lang.Long]
> 09:06:18:238 DEBUG java.sql.ResultSet - {rset-100012} ResultSet
> 09:06:18:238 DEBUG java.sql.ResultSet - {rset-100012} Header:
> [UNIQUE_PRODUCT_ID, *snip* ]
> 09:06:18:238 DEBUG java.sql.ResultSet - {rset-100012} Result:
> [30025801842, *snip* ]
> 09:06:18:238 DEBUG com.ibatis.common.jdbc.SimpleDataSource -
> Returned connection 1350937903 to pool.
> 09:06:18:238 DEBUG db.domain.pm.ibatis.IbatisProductMaintenance -
> About to execute update Product.
> 09:06:18:238 DEBUG com.ibatis.common.jdbc.SimpleDataSource - Checked
> out connection 1350937903 from pool.
> 09:06:18:238 DEBUG java.sql.Connection - {conn-100013} Connection
>
> The IbatisProudctMaintenance is my own class.  I was hoping to see
> some SqlMapClient log entries.
>
> - Paul
Mime
View raw message