jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dan Diephouse <dan.diepho...@mulesource.com>
Subject Re: Enforcing constraints; Sessions and Threading
Date Mon, 05 Nov 2007 22:09:55 GMT
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Jukka Zitting wrote:
<blockquote
 cite="mid:510143ac0711051351i20a03092n39fc3623548c1953@mail.gmail.com"
 type="cite">
  <pre wrap="">Hi,

On 11/5/07, Dan Diephouse <a class="moz-txt-link-rfc2396E" href="mailto:dan.diephouse@mulesource.com">&lt;dan.diephouse@mulesource.com&gt;</a>
wrote:
  </pre>
  <blockquote type="cite">
    <pre wrap="">Jukka Zitting wrote:
    </pre>
    <blockquote type="cite">
      <pre wrap="">There's nothing like a UNIQUE constraint in JCR or Jackrabbit (though
it might be good to have at least a Jackrabbit feature request in Jira
for that), so the closest you can get probably to make the "resource
name" be the name of the entry node and have all the entries stored as
children of a parent node that doesn't allow same-name-siblings.
      </pre>
    </blockquote>
    <pre wrap=""> OK that could work!
    </pre>
  </blockquote>
  <pre wrap=""><!---->
There's an added benefit if you plan to use the "resource name" as a
primary identifier for the entries, as you'll then be able to use
normal path resolution instead of a more expensive query to retrieve
an entry.
  </pre>
</blockquote>
Cool. <br>
<br>
Another question though - which node type do I use to disallow same
name siblings? I'm not quite keen on doing the File/Folder thing for
some reason (maybe I should be?). I don't see any other node types that
disallow same name siblings though. Does that mean I need to create my
own node type? And if I create my own node type does that mean I have
to do so via the Jackrabbit APIs? I don't see a way to do so via the
JCR API.<br>
<br>
- Dan<br>
<br>
<pre class="moz-signature" cols="72">-- 
Dan Diephouse
MuleSource
<a class="moz-txt-link-freetext" href="http://mulesource.com">http://mulesource.com</a>
| <a class="moz-txt-link-freetext" href="http://netzooid.com/blog">http://netzooid.com/blog</a></pre>
</body>
</html>

Mime
View raw message