You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jackrabbit.apache.org by Hervé Agnoux <he...@diaam-informatique.com> on 2010/02/01 21:51:11 UTC

[NEWBIE] Checkin / checkout

Hi,

I have many newbies questions about versioning. I understand I enabled 
versionning on a node with mix:versionable, as 
http://wiki.apache.org/jackrabbit/ExamplesPage?highlight=(version)#Versioning_Basics 
says.

But I don't understand what's append for childs. Are they in version system if 
a parent is mix:versionable ?

Can I do 36,000 checkout without checkin ?

Is it possible to tag a version ? 

Is there some system to do a diff between versions ?

Is it possible to search something in versions ?

Regards.


Re: [NEWBIE] Checkin / checkout

Posted by Alexander Klimetschek <ak...@day.com>.
2010/2/1 Hervé Agnoux <he...@diaam-informatique.com>:
> I have many newbies questions about versioning. I understand I enabled
> versionning on a node with mix:versionable, as
> http://wiki.apache.org/jackrabbit/ExamplesPage?highlight=(version)#Versioning_Basics
> says.

I suggest you also have a look in the JCR specs. Section 8.2 (JCR 1.0)
and 15 (2.0) cover it.

JCR 1.0:
http://jcp.org/en/jsr/detail?id=170
http://www.day.com/specs/jcr/1.0/ (html version)

JCR 2.0 (starting with Jackrabbit 2.0):
http://jcp.org/en/jsr/detail?id=283
http://www.day.com/specs/jcr/2.0/ (html version)

Also this article gives a good overview over versioning with JCR:
http://jtoee.com/jsr-170/the_jcr_primer/5/ (direct link to versioning section)

> But I don't understand what's append for childs. Are they in version system if
> a parent is mix:versionable ?

How the subtree is affected depends on the OnParentVersion (OPV)
attribute of the child node / property definition from the node type
used. See the article.

> Can I do 36,000 checkout without checkin ?

Not sure what you exactly mean by that. But generally, no, a checkout
"just" makes the "head" of a versionable node writable. A further
checkout doesn't make sense. After you have done write operations,
which can be any number of save() operations, you do a checkin to
create the next version and make the node read-only again.

> Is it possible to tag a version ?

Use version labels.

> Is there some system to do a diff between versions ?

Not in JCR or Jackrabbit. Depends too much on the content structure to
have it generically available in the repository. In most cases a
line-diff of a large string or binary property (eg. for html
documents) is probably what you want.

> Is it possible to search something in versions ?

Yes, query the version store under /jcr:system/jcr:versionStorage.

Regards,
Alex

-- 
Alexander Klimetschek
alexander.klimetschek@day.com