<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE beans PUBLIC '-//SPRING//DTD BEAN//EN' 'http://www.springframework.org/dtd/spring-beans.dtd'>

<beans>
    <!-- Client Ticket Holder -->
    <bean id="clientTicketHolder" class="org.alfresco.repo.remote.ClientTicketHolderGlobal"/>

    <!-- Remote AVM interface -->
    <bean id="avmRemote" class="org.alfresco.repo.remote.AVMRemoteImpl">
        <property name="avmRemoteTransport">
            <ref bean="avmRemoteTransport"/>
        </property>
        <property name="clientTicketHolder">
            <ref bean="clientTicketHolder"/>
        </property>
    </bean>
    
    <bean id="avmRemoteTransport" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
        <property name="serviceUrl">
            <value>rmi://localhost:50500/avm</value>
        </property>
        <property name="serviceInterface">
            <value>org.alfresco.service.cmr.remote.AVMRemoteTransport</value>
        </property>
        <property name="refreshStubOnConnectFailure">
            <value>true</value>
        </property>
    </bean>

	<bean id="avmSyncService" class="org.alfresco.repo.remote.AVMSyncServiceRemote">
	    <property name="avmSyncServiceTransport">
	    	<ref bean="avmSyncServiceTransport"/>
	    </property>
	    <property name="clientTicketHolder">
	        <ref bean="clientTicketHolder"/>
	    </property>
	</bean>

    <bean id="avmSyncServiceTransport" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
        <property name="serviceUrl">
            <value>rmi://localhost:50500/avmsync</value>
        </property>
        <property name="serviceInterface">
            <value>org.alfresco.service.cmr.remote.AVMSyncServiceTransport</value>
        </property>
        <property name="refreshStubOnConnectFailure">
            <value>true</value>
        </property>
    </bean>    
    
    <bean id="authenticationService" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
        <property name="serviceUrl">
            <value>rmi://localhost:50500/authentication</value>
        </property>
        <property name="serviceInterface">
            <value>org.alfresco.service.cmr.security.AuthenticationService</value>
        </property>
        <property name="refreshStubOnConnectFailure">
            <value>true</value>
        </property>
    </bean>
    
    <bean id="repoRemoteTransport" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
        <property name="serviceUrl">
            <value>rmi://localhost:50500/repo</value>
        </property>
        <property name="serviceInterface">
            <value>org.alfresco.service.cmr.remote.RepoRemoteTransport</value>
        </property>
        <property name="refreshStubOnConnectFailure">
            <value>true</value>
        </property>
    </bean>
    
    <bean id="repoRemote" class="org.alfresco.repo.remote.RepoRemoteImpl">
        <property name="repoRemoteTransport">
            <ref bean="repoRemoteTransport"/>
        </property>
        <property name="clientTicketHolder">
            <ref bean="clientTicketHolder"/>
        </property>
    </bean>
</beans>
