jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tobias Strasser (JIRA)" <j...@apache.org>
Subject [jira] Resolved: (JCR-232) jcr:baseVersion is not updated when the base version is removed from the version history
Date Mon, 03 Oct 2005 10:01:48 GMT
     [ http://issues.apache.org/jira/browse/JCR-232?page=all ]
     
Tobias Strasser resolved JCR-232:
---------------------------------

    Resolution: Fixed

Author: tripod
Date: Mon Oct  3 02:55:40 2005
New Revision: 293286


> jcr:baseVersion is not updated when the base version is removed from the version history
> ----------------------------------------------------------------------------------------
>
>          Key: JCR-232
>          URL: http://issues.apache.org/jira/browse/JCR-232
>      Project: Jackrabbit
>         Type: Bug
>   Components: versioning
>     Reporter: Edgar Poce
>     Assignee: Tobias Strasser
>      Fix For: 1.0

>
>         Session s1 = repo.login(new SimpleCredentials("user1", "pwd1".toCharArray()));
>         Node root1 = s1.getRootNode() ;
>         Node test1 = root1.addNode("test") ;
>         test1.addMixin("mix:versionable");
>         s1.save() ;
>         System.out.println(test1.getProperty("jcr:baseVersion").getValue().getString())
;
>         test1.checkin() ;
>         System.out.println(test1.getProperty("jcr:baseVersion").getValue().getString())
;
>         test1.getVersionHistory().removeVersion("1.0") ;
>         // the base version wasn't updated :(
>         System.out.println(test1.getProperty("jcr:baseVersion").getValue().getString())
;
>         // the next line throws ItemNotFoundException :(
>         test1.getBaseVersion() ;
> javax.jcr.ItemNotFoundException: c33bf049-c7e1-4b34-968a-63ff1b1113b0
> 	at org.apache.jackrabbit.core.ItemManager.createItemInstance(ItemManager.java:498)
> 	at org.apache.jackrabbit.core.ItemManager.getItem(ItemManager.java:349)
> 	at org.apache.jackrabbit.core.PropertyImpl.getNode(PropertyImpl.java:642)
> 	at org.apache.jackrabbit.core.NodeImpl.getBaseVersion(NodeImpl.java:2960)
> 	at org.apache.jackrabbit.core.RemoveVersionTest.main(RemoveVersionTest.java:56)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message