You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jackrabbit.apache.org by Mohinder Singh <ms...@swri.org> on 2009/10/15 22:56:01 UTC

Deleting Version

I am trying to remove the latest version and getting exception thrown.

 

Code is:

      VersionHistory vh = fileNode.getVersionHistory();

      VersionIterator vi = vh.getAllVersions();

      while(vi.hasNext())

            latestVersion = vi.nextVersion();

            

      vh.removeVersion(latestVersion.getName());

 

Exception is:

 

javax.jcr.ReferentialIntegrityException: Unable to remove version. At least
once referenced.

 

Any clues?

Thanks,

Mohinder

 

-----Original Message-----
From: Alexander Klimetschek [mailto:aklimets@day.com] 
Sent: Friday, October 09, 2009 2:50 AM
To: users@jackrabbit.apache.org
Subject: Re: Aborting Checkout

 

On Thu, Oct 8, 2009 at 20:40, Mohinder Singh <ms...@swri.org> wrote:

> If I checkout() a node, then its non-versionable tree becomes
write-enabled.

> How do I abort (don't want to make changes) this checkout() so that nodes

> tree is read-only again.

> I do not want to create another version by checkin().

 

I'd say don't change anything (session.refresh()), checkin() and

delete the unnecessary version.

 

Regards,

Alex

 

-- 

Alexander Klimetschek

alexander.klimetschek@day.com


Re: should we have mixin type or add new non mandatory properties to the primary type node

Posted by Tobias Bocanegra <tr...@day.com>.
hi,
i would add them as mixin, especially if the new properties belong to
a new semantic group. if you just forgot to add some properties  on
the primary, i would just add them there.

regards toby

On Fri, Oct 16, 2009 at 5:03 AM, Vijay K Pandey <VP...@mdes.ms.gov> wrote:
> Hello Users,
>
> We have been using JackRabbit in production env from last couple of years (currently 1.5) and we have around 5 million nodes in the repository.
>
> We have come across a new business rule in our system where we have to add couple of  "new properties" on some specific condition to any new node that we add to the repository.
>
> My question is should we go ahead and have a mixin type for this or add these properties as non mandatory to the primary node type.
>
> Any advise will be really appreciated.
>
> Thanks
> Vijay
>

Re: Deleting Version

Posted by Sébastien Launay <se...@gmail.com>.
Hi Mohinder,

You can find answers about version history deletion in the following threads:

http://markmail.org/message/7aildokt74yeoar5
http://markmail.org/message/nhbwe7o3c7pd4sga

--
Sébastien Launay

should we have mixin type or add new non mandatory properties to the primary type node

Posted by Vijay K Pandey <VP...@mdes.ms.gov>.
Hello Users,

We have been using JackRabbit in production env from last couple of years (currently 1.5) and we have around 5 million nodes in the repository.

We have come across a new business rule in our system where we have to add couple of  "new properties" on some specific condition to any new node that we add to the repository.

My question is should we go ahead and have a mixin type for this or add these properties as non mandatory to the primary node type.

Any advise will be really appreciated.

Thanks
Vijay