Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] Map-related Exception in M5

Hello Tom,

  Does adding an em.persist(data) some time before your flush help?

Unfortunately, no. Actually, em.persist(data) was there when I first encountered the exception, before I started to play around, trying to reduce sources of error. With or without the persist(): NPE.

But:

I just removed the flush(), and everything works fine now. The flush () had been there because Essentials (in our development setup) did not update the ID field after a persist() call. I think it should (it's in the spec, isn't it?), and there is a GF bug for this, #3389 to be precise.

But EclipseLink does update the ID, of course. So, no more flush()es, no more pain. I knew flush()es were evil, but I didn't know they were THAT evil. I'll go throw out all the flush() calls now and check if that solves the caching problems I was seeing some weeks ago.

Thanks for listening,

rv


Back to the top