Issue Details (XML | Word | Printable)

Key: OPENJPA-202
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Unassigned
Reporter: George Hongell
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
OpenJPA

after invoking LRS processing in a client by calling an @LRS annotated relationship, the next em.clear()/em.close() gets org.apache.openjpa.persistence.InvalidStateException: You cannot transfer large result set fields from one object or field to another

Created: 05/Apr/07 12:56 AM   Updated: 06/Apr/07 07:38 PM
Return to search
Component/s: kernel
Affects Version/s: 0.9.7
Fix Version/s: 0.9.7

Time Tracking:
Not Specified

File Attachments:
  Size
Zip Archive lrsBugWineryTest.zip 2007-04-05 12:57 AM George Hongell 29 kB
Environment: 0.9.7-incubating-SNAPSHOT

Resolution Date: 06/Apr/07 07:19 PM


 Description  « Hide
after invoking LRS processing in a client by calling an @LRS annotated relationship, the next em.clear()/em.close() gets org.apache.openjpa.persistence.InvalidStateException: You cannot transfer large result set fields from one object or field to another

<4|false|0.9.7-incubating-SNAPSHOT> org.apache.openjpa.persistence.InvalidStateException: You cannot transfer large result set fields from one object or field to another.
at org.apache.openjpa.util.AbstractLRSProxyCollection.setOwner(AbstractLRSProxyCollection.java:77)
at org.apache.openjpa.kernel.DetachManager$DetachFieldManager.reproxy(DetachManager.java:523)
at org.apache.openjpa.kernel.DetachManager.detachInternal(DetachManager.java:431)
at org.apache.openjpa.kernel.DetachManager.detachAll(DetachManager.java:299)
at org.apache.openjpa.kernel.BrokerImpl.detachAllInternal(BrokerImpl.java:3150)
at org.apache.openjpa.kernel.BrokerImpl.detachAll(BrokerImpl.java:3123)
at org.apache.openjpa.kernel.DelegatingBroker.detachAll(DelegatingBroker.java:1136)
at org.apache.openjpa.persistence.EntityManagerImpl.clear(EntityManagerImpl.java:868)
at com.ibm.websphere.ejb3sample.winetour.bug.BugWineryTest.testLargeResultSetAnnotation(BugWineryTest.java:902)
at com.ibm.websphere.ejb3sample.winetour.bug.BugWineryTest.main(BugWineryTest.java:146)

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
George Hongell added a comment - 05/Apr/07 12:57 AM
run main method to get error

Abe White added a comment - 06/Apr/07 07:19 PM
Changed detach process to never detach LRS fields. In the future we might consider enhancements like detaching write-only proxies for LRS fields. The only way to fully detach an LRS field, though, would be to read it all into memory, which would defeat the purpose. Fixed in revision 526253.

Patrick Linskey added a comment - 06/Apr/07 07:38 PM
Another possibility would be to detach the field if it is explicitly included in the fetch configuration, either directly or via a fetch group that contains it. That would let people get the data if they were willing to pay the price.