Return-Path: Delivered-To: apmail-cocoon-users-archive@www.apache.org Received: (qmail 42086 invoked from network); 5 Jun 2008 13:13:18 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 5 Jun 2008 13:13:18 -0000 Received: (qmail 11790 invoked by uid 500); 5 Jun 2008 13:13:18 -0000 Delivered-To: apmail-cocoon-users-archive@cocoon.apache.org Received: (qmail 11740 invoked by uid 500); 5 Jun 2008 13:13:18 -0000 Mailing-List: contact users-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: users@cocoon.apache.org List-Id: Delivered-To: mailing list users@cocoon.apache.org Received: (qmail 11729 invoked by uid 99); 5 Jun 2008 13:13:18 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 05 Jun 2008 06:13:17 -0700 X-ASF-Spam-Status: No, hits=2.1 required=10.0 tests=DNS_FROM_RFC_BOGUSMX,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [195.140.232.143] (HELO mail1.triplemind.com) (195.140.232.143) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 05 Jun 2008 13:12:21 +0000 Received: from [192.168.1.112] (Q711f.q.strato-dslnet.de [89.53.113.31]) (authenticated bits=0) by mail1.triplemind.com (8.14.2/8.14.2) with ESMTP id m55DCOub010952 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Thu, 5 Jun 2008 13:12:27 GMT Message-ID: <4847E68B.5040000@triplemind.com> Date: Thu, 05 Jun 2008 15:13:47 +0200 From: Imran Pariyani User-Agent: Thunderbird 1.5.0.7 (X11/20060909) MIME-Version: 1.0 To: users@cocoon.apache.org Subject: Re: multithreaded Content Aggregator migration from 2.1 to 2.2 References: <484557C5.8090506@triplemind.com> <484718F6.8030707@triplemind.com> <48471D1F.1070501@tuffmail.com> In-Reply-To: <48471D1F.1070501@tuffmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Triplemind-com-MailScanner-Information: Please contact the ISP for more information X-MailScanner-ID: m55DCOub010952 X-Triplemind-com-MailScanner: Found to be clean X-Triplemind-com-MailScanner-From: ipariyani@triplemind.com X-Virus-Checked: Checked by ClamAV on apache.org hello Grzegorz, Thanks for the reply .. and for the clue .. i guess i was looking in the wrong direction ... i will try and look into the source and also post the same to dev at cocoon .. if u find anything else on this issue please do let me know .. we cant upgrade till we solve this issue .. its quite crucial .. Grzegorz Kossakowski wrote: > Imran Pariyani pisze: >> Hi > > Hi Imran, > >> last night i wasted 5 hrs overs this without any success .. i guess >> it has something to do with passing the RequestContextListener to the >> spring context .. i have initialized the listener in my web.xml and >> also added the config in applicationcontext.xml .. i checked >> everything on my end .. everything seems to be fine .. is something >> wrong with the cachemanager present in cocoon ? >> >> any help will be greatly appreciated !! .. > > Unfortunately, it looks like you stumbled across rather complicated > (and obscure) bug. It's related to the fact how Spring's request scope > works (objects are tied to the thread). If you run multithreaded > aggregation then child threads don't have an access to beans defined > with 'request' scope because they are visible only in parent thread. > > More details below... > > > >>> org.apache.cocoon.components.source.impl.SitemapSource.toSAX(SitemapSource.java:382) >> > > The failing code is: > if (touchedOM) { > //Because of complicated flow of this source it must > maintain the cleaness of OM on its own > ObjectModel newObjectModel; > try { > newObjectModel = > (ObjectModel)manager.lookup(ObjectModel.ROLE); > } catch (ServiceException e) { > throw new SAXException("Couldn't look up Object > Model", e); > } > newObjectModel.cleanupLocalContext(); > touchedOM = false; > } > Here, manager.lookup fails because ObjectModel is a bean with request > scope. > > To be honest, I don't have an idea how this should be fixed. I guess > it's a bug of CocoonRunnable class but I don't know how to give child > threads access to parent thread variables in a safe way. > > This would require more investigation that I have no time for at the > moment, unfortunately. > > I hope it helped you a little to understand the problem. Maybe you > will find someone on dev@ mailing list that has an idea how to fix it. > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org For additional commands, e-mail: users-help@cocoon.apache.org