jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marcel Reutegger <marcel.reuteg...@gmx.net>
Subject Re: Custom PersistenceManagers - How can I get the path associated with a NodeId?
Date Tue, 24 Jun 2008 07:30:26 GMT
Hi Jerome,

you might want to have a look at the SPI in Jackrabbit. It defines interfaces at 
a higher level than the persistence manager and allows an implementation to be 
path based. a major consequence however is, that you have to implement more 
operations compared to a persistence manager. while a persistence manager only 
implements CRUD, an SPI implementation needs to implement low level JCR operations.


Jerome Banks wrote:
> Hey Folks,
>   I'm trying to implement a custom PersistenceManager, and I'm running into
> some difficulties.
> I'd like to create a PersistenceManager where Nodes are stored on a
> filesystem, in a Folder corresponding the path of the Node in the
> Repository.  This way we could have nt:file file nodes which are accessible
> by non-JCR clients, simply as files on a filesystem.
> However, the methods provided to PersistenceManager only seem to pass in
> NodeId or PropertyId, which don't seem to have a path, but simply a UUID.
> It looks like various components in Jackrabbit are able to store items on
> the filesystem, but they do so by chopping up the UUID, and creating their
> own path.  Is there any reason we couldn't just use the Node's path to start
> out with?  From the JCR API perspective, it is alway available when a Node
> or Property is created. Why can't it be accessed by the PersistenceManager?
>   Any hints on how to accomplish my goal?  I want to be able to store items
> (basically binary properties ) on a filesystem, according to their path in
> the repository.
> thx ...

View raw message