On Jun 19, 2006, at 2:17 PM, Lothar Krenzien wrote:
> The IllegalStateException occured (for me) only after synchronzied
> all methods that uses the LRUMap and with Apache Commons 3.2.
> After changed back to 3.1 I can't reproduce it. But as I mentioned
> earlier I get lots (!) of NPE in LRU map.
Yes, I am debugging the LRUMap NPE. I am not concerned with
collections 3.2 at this point.
http://issues.apache.org/cayenne/browse/CAY-565
> I posted the exception also in the apache commons group. So here's
> there answer. As I understood it could be synchronizing problem or
> a problem with immutable keys.
But you are doing the synchronization already (you patched Cayenne,
right?) and it still happens. And I am NOT using any extra
synchronization and I can't reproduce it. Ideally I do not want to
check in any "fixes" until I can consistently recreate the problem.
Still shooting in the dark, but how about we do this - can you send
me your DataMap (if you can without compromising the confidentiality
of your work; in any event do not post it to Jira), indicating which
entities change the most during the application normal execution
(maybe a few typical commit SQL logs for commits that happen right
before the errors start to show up). I want to see if there is
anything "unusual" in the mapping that I should try in my own setup.
> What I've just realized is that the DataContext is obtained like
> this :
>
> import org.objectstyle.cayenne.conf.ServletUtil.
> ...
> ServletUtil.getSessionContext(request.getSession());
>
>
> In the user guide the following two methods are descriped:
>
> BasicServletConfiguration.getDefaultContext(session);
> DataContext.getThreadDataContext();
>
> Could that cause any problems ?
No, in fact user guide needs an update.
Andrus
This archive was generated by hypermail 2.0.0 : Mon Jun 19 2006 - 07:30:25 EDT