Return-Path: Delivered-To: apmail-myfaces-users-archive@www.apache.org Received: (qmail 27837 invoked from network); 5 Dec 2010 00:23:35 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 5 Dec 2010 00:23:35 -0000 Received: (qmail 75729 invoked by uid 500); 5 Dec 2010 00:23:34 -0000 Delivered-To: apmail-myfaces-users-archive@myfaces.apache.org Received: (qmail 75687 invoked by uid 500); 5 Dec 2010 00:23:33 -0000 Mailing-List: contact users-help@myfaces.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "MyFaces Discussion" Delivered-To: mailing list users@myfaces.apache.org Received: (qmail 75679 invoked by uid 99); 5 Dec 2010 00:23:33 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 05 Dec 2010 00:23:33 +0000 X-ASF-Spam-Status: No, hits=1.5 required=10.0 tests=FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of reto.breitenmoser@gmail.com designates 74.125.82.43 as permitted sender) Received: from [74.125.82.43] (HELO mail-ww0-f43.google.com) (74.125.82.43) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 05 Dec 2010 00:23:27 +0000 Received: by wwi17 with SMTP id 17so5635625wwi.0 for ; Sat, 04 Dec 2010 16:23:05 -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 :user-agent:mime-version:to:subject:content-type; bh=u4Fu93QOD6H2m6Omx99YXJ/jyjTtgYVJEq0Hvdos/xw=; b=dMPmy9IeEpb97Z6yVb/p9fpb3zmtWQlxzVIYQ3AqUkK5cropwjhYAcdzyimBTUUyul tDibqGJG8O6oidCde5gJwV76XKGsO6zhccTHYdYdmlQvV//KGDJnuoKTs1Lj1okH4iSC N+u4f1gGIFQbVVsRwfykH7DSOaW6sAWsySvac= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:subject :content-type; b=TmQyX15IYCKkj48SG5WREbaFTEYQ110/hDQrdyZWU91sIcaWIViG+wU2A6CeMSo4Vr TVv7MqZdmgv3s4A32PwArnK3kwOkbAGjrHkXHQaQ5HPnJyz6PUxnY+i9DuxNqykLOPvz JFWt2zwU5E8ed6mSfQIFDnG+puXqW/CL61H08= Received: by 10.216.173.79 with SMTP id u57mr3368027wel.40.1291508584666; Sat, 04 Dec 2010 16:23:04 -0800 (PST) Received: from [192.168.0.2] (199-47.78-83.cust.bluewin.ch [83.78.47.199]) by mx.google.com with ESMTPS id f35sm2357970wbf.2.2010.12.04.16.23.03 (version=SSLv3 cipher=RC4-MD5); Sat, 04 Dec 2010 16:23:04 -0800 (PST) Message-ID: <4CFADB66.9040800@gmail.com> Date: Sun, 05 Dec 2010 01:23:02 +0100 From: Reto Breitenmoser User-Agent: Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.9.2.12) Gecko/20101027 Lightning/1.0b2 Thunderbird/3.1.6 MIME-Version: 1.0 To: MyFaces Discussion Subject: Orchestra, Spring and AspectJ Content-Type: multipart/alternative; boundary="------------030907030201050809000307" --------------030907030201050809000307 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Hi I'm having LazyInitializationException in my web application even if I'm using Orchestra's conversation scope. I checked already my Spring and Orchestra configurations and everything should be ok. Has it maybe something to do because I use the AspectJ support from Spring for the annotated transactions? I can see in my log files, that at the end of the transaction the entity manager is always closed and thats definitly not what I want when I use the conversation scope: DEBUG [http-8080-5] org.hibernate.engine.StatefulPersistenceContext initializing non-lazy collections TRACE [http-8080-5] org.hibernate.jdbc.JDBCContext after autocommit DEBUG [http-8080-5] org.hibernate.jdbc.ConnectionManager aggressively releasing JDBC connection TRACE [http-8080-5] org.hibernate.impl.SessionImpl after transaction completion DEBUG [http-8080-5] org.springframework.orm.jpa.EntityManagerFactoryUtils Closing JPA EntityManager TRACE [http-8080-5] org.hibernate.impl.SessionImpl closing session TRACE [http-8080-5] org.hibernate.jdbc.ConnectionManager connection already null in cleanup : no action ERROR [http-8080-5] org.hibernate.LazyInitializationException failed to lazily initialize a collection of role: The handling from the JSF beans works perfect, I have only the problem with the persistence. The application run's on tomcat6 (with the spring-instrument-tomcat.jar in the classpath), Spring 3.0.3 and JPA 2.0 (Hibernate). Best regards, Reto And here is the application.xml configuration: --------------030907030201050809000307--