openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael Dick (JIRA)" <>
Subject [jira] Commented: (OPENJPA-453) Evicting embedded object nullifies statemanager
Date Thu, 28 May 2009 14:04:45 GMT


Michael Dick commented on OPENJPA-453:

Per comments on the users mailing list this issue can be reproduced with 'vanilla' OpenJPA
(no JDO / Kodo). Ravi Palacherla provided this information on the list : 

Hi Mike,

I am able to replicate the nullpointer exception with openJPA

Exception in thread "Thread-1" java.lang.NullPointerException
       at org.apache.openjpa.kernel.StateManagerImpl.replaceObjectField(
       at Book.pcReplaceField(
       at org.apache.openjpa.kernel.StateManagerImpl.replaceField(
       at org.apache.openjpa.kernel.StateManagerImpl.clearFields(
       at org.apache.openjpa.kernel.PNonTransState.beforeWrite(
       at org.apache.openjpa.kernel.PNonTransState.beforeWrite(
       at org.apache.openjpa.kernel.StateManagerImpl.dirty(
       at org.apache.openjpa.kernel.StateManagerImpl.settingStringField(
       at Book.pcSettitle(
       at Book.setTitle(
       at Main$

You can download the test case from:

If you verify I set the property "<property name="openjpa.Multithreaded"
value="false"/>" even though I am spawning threads in my sample.

When I correct this configuration by changing MultiThreaded property to
"true" then my test case hangs.

Please let me know if you need more information.

Please validate my test case to see if it is in sync with your application.

- Ravi.

> Evicting embedded object nullifies statemanager
> -----------------------------------------------
>                 Key: OPENJPA-453
>                 URL:
>             Project: OpenJPA
>          Issue Type: Bug
>         Environment: Kodo 4.1.4, Ms sql server 2005, jTDS 1.2, jdk 1.6
>            Reporter: Christiaan
>         Attachments:
> I am noticing the following behaviour: If evict() is called on an embedded
> object the statemanager is nullified which is in contrast to non-embedded
> objects. Subsequently, calling JDOHelper.getPersistenceManager() on the
> evicted embedded object returns null. Is this the correct behaviour?

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

View raw message