jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jukka Zitting" <jukka.zitt...@gmail.com>
Subject Re: Question about root node children?
Date Tue, 31 Oct 2006 10:51:28 GMT
Hi,

On 10/31/06, Nicolas <ntoper@gmail.com> wrote:
> Actually they have different names, but the same name sibling is a use case
> I should be taking care of.
>
> Do you have an idea why with same name sibling this behaviour happens?

You've probably run code like the following a few times over:

    Session session = ...;
    Node root = session.getRootNode();
    root.addNode("A");
    root.addNode("B");
    root.addNode("C");
    session.save();

When run multiple times, this results in a repository like this:

   /
   /jcr:system
   /A[1]
   /A[2]
   /A[...]
   /B[1]
   /B[2]
   /B[...]
   /C[1]
   /C[2]
   /C[...]

BR,

Jukka Zitting

Mime
View raw message