Return-Path: Delivered-To: apmail-incubator-ibatis-user-java-archive@www.apache.org Received: (qmail 33425 invoked from network); 20 Mar 2005 02:27:25 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 20 Mar 2005 02:27:25 -0000 Received: (qmail 18899 invoked by uid 500); 20 Mar 2005 02:27:24 -0000 Delivered-To: apmail-incubator-ibatis-user-java-archive@incubator.apache.org Received: (qmail 18868 invoked by uid 500); 20 Mar 2005 02:27:24 -0000 Mailing-List: contact ibatis-user-java-help@incubator.apache.org; run by ezmlm Precedence: bulk Reply-To: ibatis-user-java@incubator.apache.org List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list ibatis-user-java@incubator.apache.org Received: (qmail 18854 invoked by uid 99); 20 Mar 2005 02:27:24 -0000 X-ASF-Spam-Status: No, hits=0.4 required=10.0 tests=DNS_FROM_RFC_ABUSE,RCVD_BY_IP,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: domain of clinton.begin@gmail.com designates 64.233.184.193 as permitted sender) Received: from wproxy.gmail.com (HELO wproxy.gmail.com) (64.233.184.193) by apache.org (qpsmtpd/0.28) with ESMTP; Sat, 19 Mar 2005 18:27:22 -0800 Received: by wproxy.gmail.com with SMTP id 68so649724wri for ; Sat, 19 Mar 2005 18:27:21 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=MO5V9wv7D8sr6c2mmYvc6tRtHFfAiklnLRLGWZYCFyn0DDAvXNuE7syi/BNjGskSg7LK0n6XTd9kOYdyPCM/eKTcQO+UDs6QZ6pS895u2L7sOf0NQjnw1hAR5RxdjlxpAjLCFUesSpHsJxq/BX4gs3Ghx3/A4Hp/9WOU0M1djws= Received: by 10.54.37.72 with SMTP id k72mr2117086wrk; Sat, 19 Mar 2005 18:27:21 -0800 (PST) Received: by 10.54.33.78 with HTTP; Sat, 19 Mar 2005 18:27:20 -0800 (PST) Message-ID: <16178eb105031918276dbf4a6f@mail.gmail.com> Date: Sat, 19 Mar 2005 19:27:20 -0700 From: Clinton Begin Reply-To: cbegin@ibatis.com To: ibatis-user-java@incubator.apache.org Subject: Re: Question regarding connection management in nested executions In-Reply-To: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit References: X-Virus-Checked: Checked X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N iBATIS should either use the same connection if one is already open, or request another one if there is no connection currently available. Do you have a stack trace and example SQL Map files and code? Clinton On Thu, 17 Mar 2005 06:57:48 -0700, Grier, Michael wrote: > I've run into problem using iBatis with an object that does lazy > loading. The scenario is a business object that has a property that is > evaluated by a dynamic SQL element. The implementation of the property > get method is that it accesses another object that may in the same > thread attempt to load data using the same SQL map config. > > The behavior of iBatis in this circumstance is that the nested execute > gets the same connection of the outer execute and ends up closing it so > that the outer call fails. > > I have several options for avoiding this problem but am wondering > whether this represents a bug in iBatis or if it is a known and accepted > limitation of the framework, or perhaps there is an obvious solution on > the iBatis side that I am missing. > > Thanks, > > Mike >