Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 87931 invoked from network); 4 Mar 2008 21:53:30 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 4 Mar 2008 21:53:30 -0000 Received: (qmail 7973 invoked by uid 500); 4 Mar 2008 21:53:22 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 7957 invoked by uid 500); 4 Mar 2008 21:53:22 -0000 Mailing-List: contact user-java-help@ibatis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user-java@ibatis.apache.org Delivered-To: mailing list user-java@ibatis.apache.org Received: (qmail 7846 invoked by uid 99); 4 Mar 2008 21:53:21 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 04 Mar 2008 13:53:21 -0800 X-ASF-Spam-Status: No, hits=2.0 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of jeffgbutler@gmail.com designates 209.85.162.182 as permitted sender) Received: from [209.85.162.182] (HELO el-out-1112.google.com) (209.85.162.182) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 04 Mar 2008 21:52:39 +0000 Received: by el-out-1112.google.com with SMTP id m34so1132898ele.9 for ; Tue, 04 Mar 2008 13:52:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; bh=ZRsrqb9fSBWAYNrN4p51JAM0X2U/7qhK+9N2GOZRHA0=; b=YC+srTULl68RX7xrY+RBjsGY25+T4eQ8ByZbNAoYgAw8wZROnZqaDI8I75SKMytnvWvbjzi8U03VFDidmpBAGQ0L8CYPURbHHMNoCOAtIyk5h6puVF8CzoBVXAHpNrBTasLq46OksO2QtoB0H+ipkrbaJriZu9aJI/CA1VS1FHw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=QQvcYbPUjpw5ZrAg21uCxGu8lTifvnX8+UylIY+PMFIK5FcGlkzygZ+Yxnj4ptRje07wdZ2AUDNqoC0/VrTg9A4GKlpcwsXc+oqIs4wPPFsCkGt28QGk0Tq0AOb8+iDSUcj6x70zxwjmmA0YFuN5zSocWO6SLDgz6FDs8EyMyv4= Received: by 10.114.125.2 with SMTP id x2mr3022364wac.119.1204667567506; Tue, 04 Mar 2008 13:52:47 -0800 (PST) Received: by 10.114.111.3 with HTTP; Tue, 4 Mar 2008 13:52:47 -0800 (PST) Message-ID: Date: Tue, 4 Mar 2008 15:52:47 -0600 From: "Jeff Butler" To: user-java@ibatis.apache.org Subject: Re: queryForList/Map/Object... rollbacks In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_17926_6350215.1204667567503" References: X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_17926_6350215.1204667567503 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline What transaction manager are you using? Is this an EJB application with CMT, or just a web application? Have you read the information in the WIKI about configuring iBATIS on WebSphere? http://opensource.atlassian.com/confluence/oss/display/IBATIS/Environment+Specific+Information Jeff Butler On Tue, Mar 4, 2008 at 3:32 PM, Tom Henricksen wrote: > We are performance monitoring our application and my DBA let me know that > we had over 3 MILLION rollbacks in a single day. We are using WebSphere to > DB2 on Win2k3 servers. > > I looked in our code and could not find anything. Used p6spy and found > that every time queryForXXX is called I received a rollback. Stepping > through the queryForList code in SqlMapExecutorDelegate.java the > autoStartTransaction starts a transaction if none is present and since we > don't have commitRequired set, the autoEndTransaction will cause a rollback. > > I assume there is a good reason to start the transaction here. It seems > like extra work creating a transaction that will always be rolled back. Can > someone explain why this is good to me so I can forward the information to > my DBA? Any links supporting the argument would be great. Is there a way > to use the queryForXXX without creating a transaction? I assume it is > better to not have commitRequired? > > Thanks for your time. > > > > *Tom Henricksen* > Consultant > Advanced Technologies Group, Inc. > > > ------=_Part_17926_6350215.1204667567503 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline
What transaction manager are you using?
Is this an EJB application with CMT, or just a web application?
Have you read the information in the WIKI about configuring iBATIS on WebSphere?
 
 
Jeff Butler


 
On Tue, Mar 4, 2008 at 3:32 PM, Tom Henricksen <TomH@a-t-g.com> wrote:

We are performance monitoring our application and my DBA let me know that we had over 3 MILLION rollbacks in a single day.  We are using WebSphere to DB2 on Win2k3 servers.

I looked in our code and could not find anything.  Used p6spy and found that every time queryForXXX is called I received a rollback.  Stepping through the queryForList code in SqlMapExecutorDelegate.java the autoStartTransaction starts a transaction if none is present and since we don't have commitRequired set, the autoEndTransaction will cause a rollback.

I assume there is a good reason to start the transaction here.  It seems like extra work creating a transaction that will always be rolled back.  Can someone explain why this is good to me so I can forward the information to my DBA?  Any links supporting the argument would be great.  Is there a way to use the queryForXXX without creating a transaction?  I assume it is better to not have commitRequired?

Thanks for your time.

 

Tom Henricksen
Consultant
Advanced Technologies Group, Inc.

 


------=_Part_17926_6350215.1204667567503--