jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kooper <sergeysach...@list.ru>
Subject rmi issue
Date Wed, 19 Aug 2009 10:14:39 GMT

Hi I have issue with regestring node via rmi. I ve read posts about how to
register node through rmi and it worked for me
To get repository use:
JackrabbitClientAdapterFactory jrFactory = new
JackrabbitClientAdapterFactory();
            ClientRepositoryFactory factory = new
ClientRepositoryFactory(jrFactory);
            repository = factory.getRepository(repositoryHome);

to register node types use:
JackrabbitNodeTypeManager ntTypeMgr = (JackrabbitNodeTypeManager)
ws.getNodeTypeManager();

but then we updated repository to 1.6.0 and it fails now, throws classcast
exeption:
//localhost:1099/jackrabbit.repository java.lang.ClassCastException?:
org.apache.jackrabbit.rmi.client.ClientNodeTypeManager? cannot be cast to
org.apache.jackrabbit.api.JackrabbitNodeTypeManagerjava?.lang.ClassCastException?:
org.apache.jackrabbit.rmi.client.ClientNodeTypeManager? cannot be cast to
org.apache.jackrabbit.api.JackrabbitNodeTypeManager? at
com.jackrabbit.tool.JackRabbitImport?.importNodeType(JackRabbitImport?.java:86)

Can any one explain what could be wrong here? 

Also we are using spring modules on server side. Could it be the reason?
here is regestring in spring:
 <bean id="localRepositoryClient"
class="org.springmodules.jcr.jackrabbit.RepositoryFactoryBean">
      <property name="configuration"
value="${repository.jr.local.configFile}"/>
      <property name="homeDir" value="${repository.jr.local.homeDir}"/>
    </bean>

    <!-- use Spring's RMI classes to retrieve the RMI registry -->
    <bean id="rmiRegistry"
class="org.springframework.remoting.rmi.RmiRegistryFactoryBean"/>
    <bean id="rmiServer"
class="org.springmodules.jcr.jackrabbit.RmiServerRepositoryFactoryBean">
        <property name="repository" ref="localRepositoryClient"/>
        <property name="remoteAdapterFactory">
            <bean
class="org.apache.jackrabbit.rmi.server.ServerAdapterFactory"/>
        </property>
        <property name="registry" ref="rmiRegistry"/>
        <property name="rmiName" value="jackrabbit.repository"/>
    </bean>

Thanks

-- 
View this message in context: http://www.nabble.com/rmi-issue-tp25041418p25041418.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.


Mime
View raw message