Return-Path: Delivered-To: apmail-incubator-cayenne-user-archive@locus.apache.org Received: (qmail 19570 invoked from network); 25 Sep 2006 14:09:22 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 25 Sep 2006 14:09:21 -0000 Received: (qmail 69195 invoked by uid 500); 25 Sep 2006 14:09:21 -0000 Delivered-To: apmail-incubator-cayenne-user-archive@incubator.apache.org Received: (qmail 69178 invoked by uid 500); 25 Sep 2006 14:09:21 -0000 Mailing-List: contact cayenne-user-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: cayenne-user@incubator.apache.org Delivered-To: mailing list cayenne-user@incubator.apache.org Received: (qmail 69169 invoked by uid 99); 25 Sep 2006 14:09:20 -0000 Received: from idunn.apache.osuosl.org (HELO idunn.apache.osuosl.org) (140.211.166.84) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Sep 2006 07:09:20 -0700 Authentication-Results: idunn.apache.osuosl.org smtp.mail=andrus@objectstyle.org; spf=permerror X-ASF-Spam-Status: No, hits=0.0 required=5.0 tests= Received-SPF: error (idunn.apache.osuosl.org: domain objectstyle.org from 64.124.179.102 cause and error) Received: from [64.124.179.102] ([64.124.179.102:58865] helo=polatsk.objectstyle.org) by idunn.apache.osuosl.org (ecelerity 2.1.1.8 r(12930)) with ESMTP id AA/B8-13750-003E7154 for ; Mon, 25 Sep 2006 07:09:06 -0700 Received: (qmail 22538 invoked from network); 25 Sep 2006 14:08:36 -0000 Received: from unknown (HELO ?J????????????/??IPv6:::1?) (127.0.0.1) by localhost with SMTP; 25 Sep 2006 14:08:36 -0000 Mime-Version: 1.0 (Apple Message framework v752.2) In-Reply-To: <4517E21D.50807@maine.rr.com> References: <570FE5C299B4CC4587C95EF5680619C1868206@FNHH-SVMEXDB003.Freenet-AG.de> <1E479DBF-D5E5-4A8F-BE71-BA2F0AF75540@objectstyle.org> <4517E21D.50807@maine.rr.com> Content-Type: text/plain; charset=ISO-8859-1; delsp=yes; format=flowed Message-Id: Content-Transfer-Encoding: quoted-printable From: Andrus Adamchik Subject: Re: NullPointerException when using shared cache Date: Mon, 25 Sep 2006 10:08:35 -0400 To: cayenne-user@incubator.apache.org X-Mailer: Apple Mail (2.752.2) X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Thanks Bryan! This is certainly helpful. Andrus On Sep 25, 2006, at 10:05 AM, Bryan Lewis wrote: > Okay, I installed the patched jar on our production servers. It'll be > difficult to say for sure that the problem was fixed, seeing as how it > happened to us only once this year. The absence of a report from me > will mean that things at least didn't get any worse. :-) > > > Andrus Adamchik wrote: >> Ayhan, Wolfgang and others who have this synchronization issue - I >> posted a patched version of 1.2.1 Cayenne: >> >> http://dev.objectstyle.org/~andrus/cayenne-1.2.1-CAY-565-=20 >> patched.tar.gz >> >> I would appreciate very much if you could test it in your environment >> and let me know whether it fixes the problem. I posted more comments >> and the exact patches that were applies on Jira: >> >> http://issues.apache.org/cayenne/browse/CAY-565 >> >> Thanks >> Andrus >> >> >> On Sep 12, 2006, at 9:35 AM, Andrus Adamchik wrote: >> >>> CAY-565 was closed as "Can not reproduce", so there was no fix. I >>> reopened this issue, bumping the priority to "Critical". I will add >>> synchronization, even though I can't test it. >>> >>> Andrus >>> >>> >>> On Sep 12, 2006, at 5:51 AM, Ayhan Kondoz wrote: >>>> Hello, >>>> >>>> >>>> >>>> I am getting NullPointerExceptions when I am trying to use the >>>> shared caching feature of cayenne. >>>> >>>> >>>> >>>> I have 3 servers. Each server has it's own tomcat / axis webservice >>>> and I have an avarage access of about 4 - 5 connections per second. >>>> Each connection results in about 3 - 4 select queries and about 20% >>>> of the connections result in an additional 2 - 3 insert / update >>>> queries. So the servers are working at pretty heavy load. >>>> >>>> >>>> >>>> Yesterday I implemented the usage of cayenne's (remote) shared >>>> caching feature using JavaGroups and at first everything seemed to >>>> work just fine. But after about 1 hour, one of the servers started >>>> to produce NullPointerExceptions on every connection. i found this >>>> bug ( http://issues.apache.org/cayenne/browse/CAY-565 ) which seems >>>> to address my problem but the status is resolved?! >>>> >>>> >>>> >>>> i tried cayenne 1.2 and 1.2B1 and in both cases got this exceptions >>>> but only if shared caching is activated. When I deactivate caching >>>> everything seems to work fine again. >>>> >>>> It seems that there is a problem with the syncronization. This =20 >>>> error >>>> occursed when under heavy load and a lot of threads are active at >>>> the same time. But if it is really a syncronization problem the =20 >>>> same >>>> error could occure on every system (even if much more unlikely) =20 >>>> even >>>> if not under heavy load. >>>> >>>> >>>> >>>> Cheers >>>> >>>> Ayhan Kondoz >>>> >>>> >>>> >>>> >>>> >>>> The exception when using common-collections 3.2 >>>> >>>> >>>> >>>> [11.09.06 21:30:32] (ERROR): Entry.next=3Dnull, >>>> data[removeIndex]=3D>>> id=3D534080>=3Dorg.objectstyle.cayenne.DataRow@fda158[values=3D=20 >>>> {suspended=3Dfalse, >>>> login=3Dchristian.hantke1, rec_create=3DTue May 02 00:00:00 CEST = 2006, >>>> rec_change=3DTue May 02 20:18:34 CEST 2006, last_updated=3DMon Sep = 11 >>>> 21:28:26 CEST 2006, cid=3D709779451, id=3D534080, mandant_id=3D3}, >>>> version=3D-9223372036854422785, replaces=3D-9223372036854775808] >>>> previous=3D>>> d=3D534080>=3Dorg.objectstyle.cayenne.DataRow@fda158[values=3D=20 >>>> {suspended=3Dfalse, >>>> login=3Dchristian.hantke1, rec_create=3DTue May 02 00:00:00 CEST = 2006, >>>> rec_change=3DTue May 02 20:18:34 CEST 2006, last_updated=3DMon Sep = 11 >>>> 21:28:26 CEST 2006, cid=3D709779451, id=3D534080, mandant_id=3D3}, >>>> version=3D-9223372036854422785, replaces=3D-9223372036854775808] =20= >>>> key=3D>>> >>>> jectId:Customer, id=3D364956> >>>> value=3Dorg.objectstyle.cayenne.DataRow@426844[values=3D=20 >>>> {suspended=3Dfalse, >>>> login=3Dnadda89, rec_create=3DThu Mar 30 00:00:00 CEST 2006, >>>> rec_change=3DThu Mar 30 22:19:00 CEST 2006, last_updated=3DFri Aug = 04 >>>> 16:09:35 CEST 2006, cid=3D705229711, id=3D364956, mandant_id=3D3}, >>>> version=3D-9223372036854407476, replaces=3D-9223372036854775808] >>>> size=3D10000 maxSize=3D10000 Please check that your keys are = immutable, >>>> and that you have used synchronization properly. If so, then please >>>> report this to commons-dev@jakarta.apache.org as a bug. >>>> >>>> java.lang.IllegalStateException: Entry.next=3Dnull, >>>> data[removeIndex]=3D>>> id=3D534080>=3Dorg.objectstyle.cayenne.DataRow@fda158[values=3D=20 >>>> {suspended=3Dfalse, >>>> login=3Dchristian.hantke1, rec_create=3DTue May 02 00:00:00 CEST = 2006, >>>> rec_change=3DTue May 02 20:18:34 CEST 2006, last_updated=3DMon Sep = 11 >>>> 21:28:26 CEST 2006, cid=3D709779451, id=3D534080, mandant_id=3D3}, >>>> version=3D-9223372036854422785, replaces=3D-9223372036854775808] >>>> previous=3D>>> id=3D534080>=3Dorg.objectstyle.cayenne.DataRow@fda158[values=3D=20 >>>> {suspended=3Dfalse, >>>> login=3Dchristian.hantke1, rec_create=3DTue May 02 00:00:00 CEST 20 = 06, >>>> rec_change=3DTue May 02 20:18:34 CEST 2006, last_updated=3DMon Sep = 11 >>>> 21:28:26 CEST 2006, cid=3D709779451, id=3D534080, mandant_id=3D3}, >>>> version=3D-9223372036854422785, replaces=3D-9223372036854775808] >>>> key=3D >>>> value=3Dorg.objectstyle.cayenne.DataRow@426844[values=3D=20 >>>> {suspended=3Dfalse, >>>> login=3Dnadda89, rec_create=3DThu Mar 30 00:00:00 CEST 2006, >>>> rec_change=3DThu Mar 30 22:19:00 CEST 2006, last_updated=3DFri Aug = 04 >>>> 16:09:35 CEST 2006, cid=3D705229711, id=3D364956, mandant_id=3D3}, >>>> version=3D-9223372036854407476, replaces=3D-9223372036854775808] >>>> size=3D10000 maxSize=3D10000 Please check that your keys are = immutable, >>>> and that you have used synchronization properly. If so, then please >>>> report this to commons-dev@jakarta.apache.org as a bug. >>>> >>>> at >>>> org.apache.commons.collections.map.LRUMap.reuseMapping=20 >>>> (LRUMap.java:300) >>>> >>>> at >>>> org.apache.commons.collections.map.LRUMap.addMapping(LRUMap.java:=20= >>>> 266) >>>> >>>> at >>>> org.apache.commons.collections.map.AbstractHashedMap.put=20 >>>> (AbstractHashedMap.java:283) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataRowStore.processUpdatedSnapshots=20= >>>> (DataRowStore.java:537) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataRowStore.processSnapshotChanges(=20= >>>> DataRowStore.java:496) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.ObjectStore.snapshotsUpdatedForObjec=20= >>>> ts(ObjectStore.java:559) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.ObjectResolver.objectsFromDataRows=20= >>>> (ObjectResolver.java:162) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.ObjectResolver.synchronizedObjectsFr=20= >>>> omDataRows(ObjectResolver.java:137) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataDomainQueryAction.interceptObjec=20= >>>> tConversion(DataDomainQueryAction.java:363) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataDomainQueryAction.execute=20 >>>> (DataDomainQueryAction.java:151) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataDomain.onQuery=20 >>>> (DataDomain.java:715) >>>> >>>> at >>>> org.objectstyle.cayenne.util.ObjectContextQueryAction.runQuery=20 >>>> (ObjectContextQueryAction.java:249) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataContextQueryAction.execute=20 >>>> (DataContextQueryAction.java:90) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataContext.onQuery=20 >>>> (DataContext.java:1320) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataContext.performQuery=20 >>>> (DataContext.java:1309) >>>> >>>> >>>> >>>> >>>> The exception when using common-collections 3.1 >>>> >>>> >>>> >>>> [11.09.06 15:29:13] (ERROR): >>>> >>>> java.lang.NullPointerException >>>> >>>> at >>>> org.apache.commons.collections.map.LRUMap.reuseMapping=20 >>>> (LRUMap.java:272) >>>> >>>> at >>>> org.apache.commons.collections.map.LRUMap.addMapping(LRUMap.java:=20= >>>> 243) >>>> >>>> at >>>> org.apache.commons.collections.map.AbstractHashedMap.put=20 >>>> (AbstractHashedMap.java:282) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataRowStore.processUpdatedSnapshots=20= >>>> (DataRowStore.java:612) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataRowStore.processSnapshotChanges(=20= >>>> DataRowStore.java:571) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataRowStore.snapshotsUpdatedForObje=20= >>>> cts(DataRowStore.java:313) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.ObjectResolver.objectsFromDataRows=20= >>>> (ObjectResolver.java:159) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.ObjectResolver.synchronizedObjectsFr=20= >>>> omDataRows(ObjectResolver.java:134) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataDomainQueryAction.interceptObjec=20= >>>> tConversion(DataDomainQueryAction.java:373) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataDomainQueryAction.execute=20 >>>> (DataDomainQueryAction.java:151) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataDomain.onQuery=20 >>>> (DataDomain.java:766) >>>> >>>> at >>>> org.objectstyle.cayenne.util.ObjectContextQueryAction.runQuery=20 >>>> (ObjectContextQueryAction.java:253) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataContextQueryAction.execute=20 >>>> (DataContextQueryAction.java:90) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataContext.onQuery=20 >>>> (DataContext.java:1422) >>>> >>>> >>>> at >>>> org.objectstyle.cayenne.access.DataContext.performQuery=20 >>>> (DataContext.java:1411) >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> Ayhan Kondoz >>>> >>>> >>>> >>>> Software-Entwicklung >>>> >>>> >>>> >>>> -------------------------------------------------------------------=20= >>>> --------------- >>>> >>>> >>>> Telefon: +49 (0) 40 513 06 616 >>>> >>>> Telefax: +49 (0) 40 513 06 998 616 >>>> >>>> E-Mail: ayhan.kondoz@freenet-ag.de >>>> >>>> >>>> Website: http://www.freenet.de ; >>>> http://www.freenet-ag.de >>>> >>>> -------------------------------------------------------------------=20= >>>> --------------- >>>> >>>> >>>> freenet.de AG >>>> >>>> Deelb=F6genkamp 4c >>>> >>>> 22297 Hamburg >>>> >>>> -------------------------------------------------------------------=20= >>>> --------------- >>>> >>>> >>>> Vorsitzender des Aufsichtsrates: Prof. Dr. Helmut Thoma >>>> >>>> Vorstand: Eckhard Spoerr (Vors.), >>>> Axel Krieger, Stephan Esch, Eric Berger >>>> >>>> Amtsgericht Hamburg HRB 74048 >>>> >>>> >>>> >>>> >>>> >>>> Diese Information ist ausschlie=DFlich f=FCr die adressierte Person = =20 >>>> oder >>>> Organisation bestimmt und k=F6nnte vertrauliches und/oder >>>> privilegiertes Material enthalten. Personen oder Organisationen, =20= >>>> f=FCr >>>> die diese Information nicht bestimmt ist, ist es nicht gestattet, >>>> diese zu lesen, erneut zu =FCbertragen, zu verbreiten, anderweitig = zu >>>> verwenden oder sich durch sie veranlasst zu sehen, Ma=DFnahmen >>>> irgendeiner Art zu ergreifen. Sollten Sie diese Nachricht =20 >>>> irrt=FCmlich >>>> erhalten haben, bitten wir Sie, sich mit dem Absender in Verbindung >>>> zu setzen und das Material von Ihrem Computer zu l=F6schen. >>>> >>>> >>>> >>>> The information transmitted is intended only for the person or >>>> entity to which it is addressed and may contain confidential and/or >>>> privileged material. Any review, retransmission, dissemination or >>>> other use of, or taking of any action in reliance upon, this >>>> information by persons or entities other than the intended =20 >>>> recipient >>>> is prohibited. If you received this in error, please contact the >>>> sender and delete the material from any computer. >>>> >>>> >>>> >>> >>> >> > > >