jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tanju Erinmez" <tanju.erin...@gmail.com>
Subject Versioning not working with InMemPersistenceManager
Date Wed, 21 Jun 2006 22:14:41 GMT
Greetings,

I'm investigating the mentioned PM to speed up unit testing when I
noticed that it throws a NoSuchItemStateException in connection with
versioning (neither jackrabbit-core-1.0.1 nor latest from trunk work).

After looking into the code a bit of InMemPersistenceManager.java, I
got the impression that the wrong store map seems to be populated
(stateStore instead of refsStore). I changed the code accordingly in
store(NodeReferences refs) and destroy(NodeReferences refs) and the
versioning runs fine (at least for me).

Is this a viable fix?

TIA,
Tanju

---------

CONFIG:
default repository.xml except the following in sections <Workspace>
and <Versioning>:
<PersistenceManager
class="org.apache.jackrabbit.core.state.mem.InMemPersistenceManager">
  <param name="persistent" value="false"/>
</PersistenceManager>


TRACE:
Exception in thread "main" javax.jcr.RepositoryException:
/resources/jcr:baseVersion: unable to update item.:
4ab7c8b0-c685-4371-9d82-a6feb9d03481:
4ab7c8b0-c685-4371-9d82-a6feb9d03481
	at org.apache.jackrabbit.core.ItemImpl.save(ItemImpl.java:1216)
	at org.apache.jackrabbit.core.NodeImpl.checkin(NodeImpl.java:2891)
	at VersioningAndWorkspaces.setupReview(VersioningAndWorkspaces.java:199)
	at VersioningAndWorkspaces.main(VersioningAndWorkspaces.java:53)
Caused by: org.apache.jackrabbit.core.state.NoSuchItemStateException:
4ab7c8b0-c685-4371-9d82-a6feb9d03481
	at org.apache.jackrabbit.core.state.SharedItemStateManager.getNodeReferences(SharedItemStateManager.java:307)
	at org.apache.jackrabbit.core.state.SharedItemStateManager.updateReferences(SharedItemStateManager.java:995)
	at org.apache.jackrabbit.core.state.SharedItemStateManager$Update.begin(SharedItemStateManager.java:484)
	at org.apache.jackrabbit.core.state.SharedItemStateManager.beginUpdate(SharedItemStateManager.java:687)
	at org.apache.jackrabbit.core.state.SharedItemStateManager.update(SharedItemStateManager.java:717)
	at org.apache.jackrabbit.core.state.LocalItemStateManager.update(LocalItemStateManager.java:316)
	at org.apache.jackrabbit.core.state.XAItemStateManager.update(XAItemStateManager.java:323)
	at org.apache.jackrabbit.core.state.LocalItemStateManager.update(LocalItemStateManager.java:292)
	at org.apache.jackrabbit.core.state.SessionItemStateManager.update(SessionItemStateManager.java:258)
	at org.apache.jackrabbit.core.ItemImpl.save(ItemImpl.java:1208)

Mime
View raw message