This content has been marked as final.
Show 3 replies
-
1. Re: JBoss PojoCache 2.0: Bug in CachedListImpl?
ben.wang Dec 11, 2006 8:23 PM (in response to chasta)I do have a test case:
org.jboss.cache.pojo.collection.CachedListTest that has test for list size after insertion. Can you try that or produce a test case for me?
Thanks!
-ben -
2. Re: JBoss PojoCache 2.0: Bug in CachedListImpl?
chasta Dec 12, 2006 9:16 AM (in response to chasta)Hi,
I've ran the test, and indeed it works in its current form - but not when using optimistic locking (e.g. subsistute 'local-service.xml' in 'replAsync-optimistic-service' in the setUp() method). Results of running unit tests from yesterday's CVS version:Before (using local-service.xml): [junit] Running org.jboss.cache.pojo.collection.CachedListTest [junit] Tests run: 9, Failures: 0, Errors: 0, Time elapsed: 15.437 sec [junit] Running org.jboss.cache.pojo.collection.CachedListTxTest ? After (using replAsync-optimistic-service.xml): [junit] Running org.jboss.cache.pojo.collection.CachedListTest [junit] Tests run: 9, Failures: 7, Errors: 0, Time elapsed: 43.203 sec [junit] Test org.jboss.cache.pojo.collection.CachedListTest FAILED
I think the problem is that the getChildren() call goes to an OptimisticTreeNode and not to a WorkspaceNode (though WorkspaceNodeImpl doesn't handle getChildren() at all?). The children are not taken from the workspace and so the check of the list size by using getChildren() does not work correctly in optimistic locking mode. Perhaps a simpler way for checking the size (w/o getting the children set) is possible. -
3. Re: JBoss PojoCache 2.0: Bug in CachedListImpl?
ben.wang Dec 13, 2006 12:53 AM (in response to chasta)OK, this is a bug we will fix then. I have created a Jira to track it.
http://jira.jboss.com/jira/browse/JBCACHE-904
Thanks!