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">
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<body bgcolor="#ffffff" text="#000000">
Jukka Zitting wrote:
  <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>
  <blockquote type="cite">
    <pre wrap="">Jukka Zitting wrote:
    <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 wrap=""> OK that could work!
  <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.
Cool. <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>
- Dan<br>
<pre class="moz-signature" cols="72">-- 
Dan Diephouse
<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>

View raw message