openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daryl Stultz <>
Subject Re: Unmanaged Object Problems
Date Mon, 05 Apr 2010 12:31:33 GMT
On Sun, Apr 4, 2010 at 12:12 PM, C N Davies <> wrote:

> This is a problem that continues to haunt me intermittently since I first
> started using OpenJPA and cannot understand why it comes up from time to
> time for no apparent reason.

Hi Chris, when you say it's "intermittent" do you mean it's not
reproducible? If you recall, I ran into the same crash from time to time. I
was able to reproduce the stack trace with a unit test but was never sure if
my live app was failing for the same reason. My unit test would try to merge
an object that had a reference to an object that was attached to a
*different* em. So the error message says it's unmanaged but it's actually
managed by another em. I found a gaping hole in my em management routine
that was leaving em's open under a certain race condition. It's a plausible
scenario that could bring my app and unit test together. So you might study
your app and see if it's possible the failedObject could be attached to a
different em.

Daryl Stultz
6 Degrees Software and Consulting, Inc.

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message