You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jackrabbit.apache.org by mansi goel <ma...@gmail.com> on 2019/04/16 05:35:46 UTC

need help on jackrabbit versioning

hi,
we are new to jackrabbit and won't be able to find documents related to
versioning functionality of jackrabbit.
It would be great if you can reply to my below queries:
1. By default, jackrabbit provides versioning of item stored in it as
1.1,1.2,1.3,1.4...... But we want versions of items should be incremented
by 1 such as 1,2,3,4... Can you please let me know how can I achieve this.
2. Jackrabbit versioning of items is 1.1,1.2,1.3,1.4...When does it come on
2.0,2.1...?does it even comes on 2.0?
3. How to rollback the previous version. Example: if version history of an
item contains the following versions 1.1,1.2 and 1.3. Now I want to
rollback the changes of version 1.2. Now 1.2 version should checkin
automatically and version got increment as 1.4. Now version history will
have the following versions 1.1,1.2,1.3,1.4. so is there any direct
jackrabbit support API to make the previous version as the current version.

We are completely stuck on versioning functionality and missing our
deadlines.It would be really helpful if you can provide any input.

Thanks and regards,
Mansi Goel

Re: need help on jackrabbit versioning

Posted by Julian Reschke <ju...@gmx.de>.
On 16.04.2019 07:35, mansi goel wrote:
> hi,
> we are new to jackrabbit and won't be able to find documents related to
> versioning functionality of jackrabbit.
> It would be great if you can reply to my below queries:
> 1. By default, jackrabbit provides versioning of item stored in it as
> 1.1,1.2,1.3,1.4...... But we want versions of items should be incremented
> by 1 such as 1,2,3,4... Can you please let me know how can I achieve this.

I believe this is hard-wired into Jackrabbit.

Note the version numbers are considered an implementation detail. You
may want to look at user-assigned version labels.

> 2. Jackrabbit versioning of items is 1.1,1.2,1.3,1.4...When does it come on
> 2.0,2.1...?does it even comes on 2.0?

I don't think it does.

> 3. How to rollback the previous version. Example: if version history of an
> item contains the following versions 1.1,1.2 and 1.3. Now I want to
> rollback the changes of version 1.2. Now 1.2 version should checkin
> automatically and version got increment as 1.4. Now version history will
> have the following versions 1.1,1.2,1.3,1.4. so is there any direct
> jackrabbit support API to make the previous version as the current version.
>
> We are completely stuck on versioning functionality and missing our
> deadlines.It would be really helpful if you can provide any input.

Have a look at
<https://docs.adobe.com/content/docs/en/spec/jcr/2.0/15_Versioning.html#15.7%20Restoring%20a%20Version>
and
<https://docs.adobe.com/docs/en/spec/javax.jcr/javadocs/jcr-2.0/javax/jcr/version/VersionManager.html#restore(javax.jcr.version.Version,%20boolean)>.

Best regards, Julian