From users-return-15413-apmail-jackrabbit-users-archive=jackrabbit.apache.org@jackrabbit.apache.org Sun Jun 13 23:07:27 2010 Return-Path: Delivered-To: apmail-jackrabbit-users-archive@minotaur.apache.org Received: (qmail 53936 invoked from network); 13 Jun 2010 23:07:27 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 13 Jun 2010 23:07:27 -0000 Received: (qmail 14177 invoked by uid 500); 13 Jun 2010 23:07:26 -0000 Delivered-To: apmail-jackrabbit-users-archive@jackrabbit.apache.org Received: (qmail 14126 invoked by uid 500); 13 Jun 2010 23:07:25 -0000 Mailing-List: contact users-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@jackrabbit.apache.org Delivered-To: mailing list users@jackrabbit.apache.org Received: (qmail 14117 invoked by uid 99); 13 Jun 2010 23:07:25 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 13 Jun 2010 23:07:25 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of tripod@day.com designates 207.126.148.95 as permitted sender) Received: from [207.126.148.95] (HELO eu3sys201amo011.postini.com) (207.126.148.95) by apache.org (qpsmtpd/0.29) with SMTP; Sun, 13 Jun 2010 23:07:19 +0000 Received: from source ([74.125.82.54]) by eu3sys201aob105.postini.com ([207.126.154.11]) with SMTP ID DSNKTBVkkLJGcYv8+Ra3pTsl1E7ukOeUAbu4@postini.com; Sun, 13 Jun 2010 23:06:58 UTC Received: by wwb22 with SMTP id 22so3652531wwb.41 for ; Sun, 13 Jun 2010 16:06:56 -0700 (PDT) MIME-Version: 1.0 Received: by 10.216.85.85 with SMTP id t63mr1577841wee.86.1276470415302; Sun, 13 Jun 2010 16:06:55 -0700 (PDT) Received: by 10.216.186.195 with HTTP; Sun, 13 Jun 2010 16:06:55 -0700 (PDT) In-Reply-To: References: <516017.80226.qm@web110111.mail.gq1.yahoo.com> Date: Mon, 14 Jun 2010 01:06:55 +0200 Message-ID: Subject: Re: Cancel checkout From: Tobias Bocanegra To: users@jackrabbit.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org hi, this is how it's specified by jsr283. see comments about restore and simple-versioning http://www.day.com/specs/jcr/2.0/15_Versioning.html mainly: 15.7.1 Simple vs. Full Versioning Before Restore Under simple versioning, if N is checked-in then it is automatically checked-out before the restore is performed. .... 15.7.7 Simple vs. Full Versioning after Restore Under simple versioning N is automatically checked-in. ... But i can see the need for a 'cancel checkout' also for simple versioning. maybe jsr283 is not too clear about that, but IMO a restore to the base version should not create a new version for simple versioning, neither. because it makes no sense. maybe you can create a jira issue for this so we can follow up on this? regards, toby On Thu, Jun 10, 2010 at 8:58 AM, Dieter Wachters wrote: > Hi, > I am using simple versioning. Can this also be considered an issue or is = this intended behavior for simple versioning? > > Regards, > > Dieter > > > Dieter Wachters > Architect > direct: > dieter.wachters@lettergen.com > > LetterGen > Groene Hofstraat 31 > 2850 Boom > Belgium > www.lettergen.com > tel: +32 3 450 89 80 > fax: +32 3 450 89 89 > > - DISCLAIMER - > This message contains confidential information and is intended only for u= sers@jackrabbit.apache.org. If you are not users@jackrabbit.apache.org, you= should not disseminate, distribute or copy this e-mail. Please notify diet= er.wachters@lettergen.com immediately by e-mail if you have received this e= -mail by mistake and delete this e-mail from your system. E-mail transmissi= on cannot be guaranteed to be secure or error-free as information could be = intercepted, corrupted, lost, destroyed, arrive late or incomplete, or cont= ain viruses. Dieter Wachters therefore does not accept liability for any er= rors or omissions in the contents of this message, which arise as a result = of e-mail transmission. If verification is required please request a hard-c= opy version. > -------------------------------------------------------------------------= - > > -----Original Message----- > > From: Tobias Bocanegra [mailto:tobias.bocanegra@day.com] > Sent: donderdag 10 juni 2010 12:09 > To: users@jackrabbit.apache.org > Subject: Re: Cancel checkout > > hi, > restoring the base version is the proper way to "cancel" a checkout. i > quickly tested it and it works. > restore never creates a version (unless you are doing simple versioning). > > if this does not work for you, please create a jira issue, and > optionally a test case. > > regards, toby > > On Wed, Jun 9, 2010 at 2:10 PM, Dieter Wachters > wrote: >> No that creates a new version, which I don't want. >> >> >> Dieter Wachters >> Architect >> direct: >> dieter.wachters@lettergen.com >> >> LetterGen >> Groene Hofstraat 31 >> 2850 Boom >> Belgium >> www.lettergen.com >> tel: +32 3 450 89 80 >> fax: +32 3 450 89 89 >> >> - DISCLAIMER - >> This message contains confidential information and is intended only for = users@jackrabbit.apache.org. If you are not users@jackrabbit.apache.org, yo= u should not disseminate, distribute or copy this e-mail. Please notify die= ter.wachters@lettergen.com immediately by e-mail if you have received this = e-mail by mistake and delete this e-mail from your system. E-mail transmiss= ion cannot be guaranteed to be secure or error-free as information could be= intercepted, corrupted, lost, destroyed, arrive late or incomplete, or con= tain viruses. Dieter Wachters therefore does not accept liability for any e= rrors or omissions in the contents of this message, which arise as a result= of e-mail transmission. If verification is required please request a hard-= copy version. >> ------------------------------------------------------------------------= -- >> >> -----Original Message----- >> >> From: Paco Avila [mailto:monkiki@gmail.com] >> Sent: woensdag 9 juni 2010 12:47 >> To: users@jackrabbit.apache.org >> Subject: Re: Cancel checkout >> >> I think is as simple as: >> >> node.restore(node.getBaseVersion(), true); >> >> On Wed, Jun 9, 2010 at 11:56 AM, Dieter Wachters >> wrote: >>> Hi, >>> >>> I might have found a solution that seems to work at first sight, but wo= uld like to hear if this isn't breaking something. >>> I use the restore method and then remove the latest version again. So I= get something like: >>> =A0 =A0 =A0 =A0final VersionManager vm =3D session.getWorkspace().getVe= rsionManager(); >>> =A0 =A0 =A0 =A0vm.restore(session.getWorkspace().getVersionManager().ge= tBaseVersion(path), true); >>> =A0 =A0 =A0 =A0final Node baseVersion =3D vm.getBaseVersion(path); >>> =A0 =A0 =A0 =A0final VersionHistory vh =3D vm.getVersionHistory(path); >>> =A0 =A0 =A0 =A0vh.removeVersion(baseVersion.getName()); >>> >> >> -- >> OpenKM >> http://www.openkm.com >> http://www.guia-ubuntu.org >> >> > >