You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openjpa.apache.org by "Michael Dick (JIRA)" <ji...@apache.org> on 2010/04/16 22:04:24 UTC

[jira] Created: (OPENJPA-1633) Provide more information when refreshing an Entity which has been deleted.

Provide more information when refreshing an Entity which has been deleted. 
---------------------------------------------------------------------------

                 Key: OPENJPA-1633
                 URL: https://issues.apache.org/jira/browse/OPENJPA-1633
             Project: OpenJPA
          Issue Type: Bug
          Components: jpa
            Reporter: Michael Dick
            Priority: Minor


This issue was originally raised on the user's mailing list at http://n2.nabble.com/EntityNotFoundException-caused-by-EntityManager-refresh-td4901557.html#a4901557. 

If you have a toMany relationship and are cascading the REFRESH operation an EntityNotFondException may occur if any of the rows on the toMany side have been deleted. 

Finding which rows didn't exist is a bit tricky. You'll need go through two sets of nested exceptions to get to the rows that were deleted, and then you only get the primary keys, not the table / entity name.

We should add the table name / entity name to the message if possible and promote them to the higher level exception.  

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira