Hi,

On 4/12/06, Tim O'Brien <[EMAIL PROTECTED]> 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.

BR,

Jukka Zitting

--
Yukatan - http://yukatan.fi/ - [EMAIL PROTECTED]
Software craftsmanship, JCR consulting, and Java development

Reply via email to