You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Marcel Reutegger (JIRA)" <ji...@apache.org> on 2007/12/18 16:15:43 UTC

[jira] Created: (JCR-1275) NullPointerException in AbstractVersionManager.createVersionHistory()

NullPointerException in AbstractVersionManager.createVersionHistory()
---------------------------------------------------------------------

                 Key: JCR-1275
                 URL: https://issues.apache.org/jira/browse/JCR-1275
             Project: Jackrabbit
          Issue Type: Bug
          Components: jackrabbit-core, versioning
            Reporter: Marcel Reutegger
            Priority: Minor


Running ConcurrentCheckinMixedTransactionTest with 200 threads results in NullPointerExceptions in AbstractVersionManager.

Exception in thread "Thread-16" java.lang.NullPointerException
	at org.apache.jackrabbit.core.version.AbstractVersionManager.createVersionHistory(AbstractVersionManager.java:309)
	at org.apache.jackrabbit.core.version.XAVersionManager.createVersionHistory(XAVersionManager.java:145)
	at org.apache.jackrabbit.core.ItemImpl.initVersionHistories(ItemImpl.java:785)
	at org.apache.jackrabbit.core.ItemImpl.save(ItemImpl.java:1221)
	at org.apache.jackrabbit.core.SessionImpl.save(SessionImpl.java:897)
	at org.apache.jackrabbit.core.ConcurrentCheckinMixedTransactionTest$1$1.execute(ConcurrentCheckinMixedTransactionTest.java:66)
	at org.apache.jackrabbit.core.AbstractConcurrencyTest$Executor.run(AbstractConcurrencyTest.java:110)
	at java.lang.Thread.run(Thread.java:619)

I'm not sure why the node that is created by the current thread is not available. I assume that some other thread using XA transactions is committing changes while the current thread creates the node. The changes from the committing thread then overwrite the node that has been modified by the current thread. The write lock is somewhat bypassed in that case.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (JCR-1275) NullPointerException in AbstractVersionManager.createVersionHistory()

Posted by "Marcel Reutegger (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JCR-1275?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Marcel Reutegger updated JCR-1275:
----------------------------------

    Attachment: JCR-1275.patch

This is the best I can come up with. Not a nice solution but at least according to spec.

> NullPointerException in AbstractVersionManager.createVersionHistory()
> ---------------------------------------------------------------------
>
>                 Key: JCR-1275
>                 URL: https://issues.apache.org/jira/browse/JCR-1275
>             Project: Jackrabbit
>          Issue Type: Bug
>          Components: jackrabbit-core, versioning
>            Reporter: Marcel Reutegger
>            Priority: Minor
>         Attachments: JCR-1275.patch
>
>
> Running ConcurrentCheckinMixedTransactionTest with 200 threads results in NullPointerExceptions in AbstractVersionManager.
> Exception in thread "Thread-16" java.lang.NullPointerException
> 	at org.apache.jackrabbit.core.version.AbstractVersionManager.createVersionHistory(AbstractVersionManager.java:309)
> 	at org.apache.jackrabbit.core.version.XAVersionManager.createVersionHistory(XAVersionManager.java:145)
> 	at org.apache.jackrabbit.core.ItemImpl.initVersionHistories(ItemImpl.java:785)
> 	at org.apache.jackrabbit.core.ItemImpl.save(ItemImpl.java:1221)
> 	at org.apache.jackrabbit.core.SessionImpl.save(SessionImpl.java:897)
> 	at org.apache.jackrabbit.core.ConcurrentCheckinMixedTransactionTest$1$1.execute(ConcurrentCheckinMixedTransactionTest.java:66)
> 	at org.apache.jackrabbit.core.AbstractConcurrencyTest$Executor.run(AbstractConcurrencyTest.java:110)
> 	at java.lang.Thread.run(Thread.java:619)
> I'm not sure why the node that is created by the current thread is not available. I assume that some other thread using XA transactions is committing changes while the current thread creates the node. The changes from the committing thread then overwrite the node that has been modified by the current thread. The write lock is somewhat bypassed in that case.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (JCR-1275) NullPointerException in AbstractVersionManager.createVersionHistory()

Posted by "Marcel Reutegger (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JCR-1275?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Marcel Reutegger resolved JCR-1275.
-----------------------------------

       Resolution: Fixed
    Fix Version/s: 1.5

Assumed lazy consensus and committed the patch in revision: 633405

> NullPointerException in AbstractVersionManager.createVersionHistory()
> ---------------------------------------------------------------------
>
>                 Key: JCR-1275
>                 URL: https://issues.apache.org/jira/browse/JCR-1275
>             Project: Jackrabbit
>          Issue Type: Bug
>          Components: jackrabbit-core, versioning
>            Reporter: Marcel Reutegger
>            Priority: Minor
>             Fix For: 1.5
>
>         Attachments: JCR-1275.patch
>
>
> Running ConcurrentCheckinMixedTransactionTest with 200 threads results in NullPointerExceptions in AbstractVersionManager.
> Exception in thread "Thread-16" java.lang.NullPointerException
> 	at org.apache.jackrabbit.core.version.AbstractVersionManager.createVersionHistory(AbstractVersionManager.java:309)
> 	at org.apache.jackrabbit.core.version.XAVersionManager.createVersionHistory(XAVersionManager.java:145)
> 	at org.apache.jackrabbit.core.ItemImpl.initVersionHistories(ItemImpl.java:785)
> 	at org.apache.jackrabbit.core.ItemImpl.save(ItemImpl.java:1221)
> 	at org.apache.jackrabbit.core.SessionImpl.save(SessionImpl.java:897)
> 	at org.apache.jackrabbit.core.ConcurrentCheckinMixedTransactionTest$1$1.execute(ConcurrentCheckinMixedTransactionTest.java:66)
> 	at org.apache.jackrabbit.core.AbstractConcurrencyTest$Executor.run(AbstractConcurrencyTest.java:110)
> 	at java.lang.Thread.run(Thread.java:619)
> I'm not sure why the node that is created by the current thread is not available. I assume that some other thread using XA transactions is committing changes while the current thread creates the node. The changes from the committing thread then overwrite the node that has been modified by the current thread. The write lock is somewhat bypassed in that case.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (JCR-1275) NullPointerException in AbstractVersionManager.createVersionHistory()

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JCR-1275?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jukka Zitting updated JCR-1275:
-------------------------------

    Affects Version/s: 1.4
                       core 1.4.1
        Fix Version/s:     (was: 1.5)
                       core 1.4.2

Merged to the 1.4 branch in revision 636750.

> NullPointerException in AbstractVersionManager.createVersionHistory()
> ---------------------------------------------------------------------
>
>                 Key: JCR-1275
>                 URL: https://issues.apache.org/jira/browse/JCR-1275
>             Project: Jackrabbit
>          Issue Type: Bug
>          Components: jackrabbit-core, versioning
>    Affects Versions: 1.4, core 1.4.1
>            Reporter: Marcel Reutegger
>            Priority: Minor
>             Fix For: core 1.4.2
>
>         Attachments: JCR-1275.patch
>
>
> Running ConcurrentCheckinMixedTransactionTest with 200 threads results in NullPointerExceptions in AbstractVersionManager.
> Exception in thread "Thread-16" java.lang.NullPointerException
> 	at org.apache.jackrabbit.core.version.AbstractVersionManager.createVersionHistory(AbstractVersionManager.java:309)
> 	at org.apache.jackrabbit.core.version.XAVersionManager.createVersionHistory(XAVersionManager.java:145)
> 	at org.apache.jackrabbit.core.ItemImpl.initVersionHistories(ItemImpl.java:785)
> 	at org.apache.jackrabbit.core.ItemImpl.save(ItemImpl.java:1221)
> 	at org.apache.jackrabbit.core.SessionImpl.save(SessionImpl.java:897)
> 	at org.apache.jackrabbit.core.ConcurrentCheckinMixedTransactionTest$1$1.execute(ConcurrentCheckinMixedTransactionTest.java:66)
> 	at org.apache.jackrabbit.core.AbstractConcurrencyTest$Executor.run(AbstractConcurrencyTest.java:110)
> 	at java.lang.Thread.run(Thread.java:619)
> I'm not sure why the node that is created by the current thread is not available. I assume that some other thread using XA transactions is committing changes while the current thread creates the node. The changes from the committing thread then overwrite the node that has been modified by the current thread. The write lock is somewhat bypassed in that case.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.