You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xmlbeans.apache.org by "Radu Preotiuc-Pietro (JIRA)" <xm...@xml.apache.org> on 2008/12/01 19:37:45 UTC
[jira] Updated: (XMLBEANS-328) Problems in multi-processor
environment
[ https://issues.apache.org/jira/browse/XMLBEANS-328?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Radu Preotiuc-Pietro updated XMLBEANS-328:
------------------------------------------
Attachment: xbean.jar
Mathieu's patch synchronizes methods in Xobj.java, but that class should be kept unsynchronized so I moved the synchronization up in the call chain in XmlObjectBase.java
Since so many people have hit this, I would appreciate you guys trying out this re-written patch and letting me know if it works. If it does, I will check it in.
I am attaching a pre-built jar with the patch applied on top of XMLBeans 2.4.0 release, I will also attach the source tomorrow so it can be built against most other versions.
> Problems in multi-processor environment
> ---------------------------------------
>
> Key: XMLBEANS-328
> URL: https://issues.apache.org/jira/browse/XMLBEANS-328
> Project: XMLBeans
> Issue Type: Bug
> Affects Versions: Version 2.2, Version 2.2.1
> Environment: At least Win XP and Linux 2.6 with Sun JRE. Intel multi-core processor.
> Reporter: Pasi Lehtimaki
> Priority: Critical
> Attachments: patch-xmlbeans-2.2.0, xbean.jar
>
>
> Running a strongly threadded Eclipse application using xmlbeans in multi-processor (/multi-core) computer causes frequent crashes in xmlbeans code.
> Most of the crases happen in Cur.java in form of a NPE:
> ***************************************************
> java.lang.NullPointerException
> at org.apache.xmlbeans.impl.store.Cur.listRemove(Cur.java:2783)
> at org.apache.xmlbeans.impl.store.Locale.getCur(Locale.java:2775)
> at org.apache.xmlbeans.impl.store.Locale.tempCur(Locale.java:2736)
> at org.apache.xmlbeans.impl.store.Locale.tempCur(Locale.java:2731)
> at org.apache.xmlbeans.impl.store.Xobj.tempCur(Xobj.java:348)
> at org.apache.xmlbeans.impl.store.Xobj.new_cursor(Xobj.java:1810)
> at org.apache.xmlbeans.impl.values.XmlObjectBase.newCursor(XmlObjectBase.java:250)
> at org.apache.xmlbeans.impl.values.XmlObjectBase.selectPath(XmlObjectBase.java:424)
> at org.apache.xmlbeans.impl.values.XmlObjectBase.selectPath(XmlObjectBase.java:415)
> ***************************************************
> In some cases the crash happens in Locale.exit():
> ***************************************************
> Exception occurred: java.lang.ArrayIndexOutOfBoundsException: -1
> at org.apache.xmlbeans.impl.store.Locale.exit(Locale.java:2840)
> ***************************************************
> This problem problem occurs in xmlbeans 2.2. and in the latest version in SVN. The problem disappears when I turn the multi-core support off from BIOS and reappears again immediently when I turn it back on. So I believe that this has something to do with threading. Only classes Locale.java and Cur.java seem to be affected. I haven't encountered any exceptions from other classes.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@xmlbeans.apache.org
For additional commands, e-mail: dev-help@xmlbeans.apache.org