jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jukka Zitting" <jukka.zitt...@gmail.com>
Subject Re: Loading a Node Type using the RMI client
Date Wed, 12 Apr 2006 16:24:41 GMT

On 4/12/06, Tim O'Brien <tobrien-asf@discursive.com> wrote:
> NodeTypeManagerImpl ntmgr = (NodeTypeManageImpl) ws.getNodeTypeManager();
> [...]
> But, it threw a ClassCastException when I tried to cast to the node type
> manager implementation.   I'm assuming that the NodeTypeManagerImpl isn't
> available when you access a repository over RMI.  Correct assumption?  If
> so, is there any way to do this over RMI?

Yes, you are right. JCR-RMI provides the client with adapter instances
that implement the standard JCR interfaces but does not expose more
features of the underlying server classes.

It would be possible possible to extend the JCR-RMI interfaces to
extend the public Jackrabbit extension interfaces in
org.apache.jackrabbit.api, but that would bring in a dependency to
Jackrabbit. A better option would perhaps be to make a jackrabbit-rmi
extension to JCR-RMI that would use the custom extensions. The
AdapterFactory approach in JCR-RMI should even make this relatively
painless. You may want to file a feature request about this in Jira.

The short term workaround is to do all nodetype management using a
local repository instance.


Jukka Zitting

Yukatan - http://yukatan.fi/ - info@yukatan.fi
Software craftsmanship, JCR consulting, and Java development
View raw message