jgroup.core.registry
Interface RegistryLocator

All Known Implementing Classes:
RelacsRegistryLocator

public interface RegistryLocator

This interface is the service provider interface for the registry location service. It is used by Jgroup to identify classes that are able to retrieve proxies for registry service implementations and create registry replicas.

Since:
Jgroup 0.8
Author:
Alberto Montresor, Hein Meling

Method Summary
 DependableRegistry createRegistry()
          Creates and exports a dependable registry replica on the local host listening for incoming requests on an the port specified in the system configuration file.
 DependableRegistry createRegistry(java.rmi.server.RMIClientSocketFactory csf, java.rmi.server.RMIServerSocketFactory ssf)
          Creates and exports a dependable registry replica on the local host listening for incoming requests on an the port specified in the system configuration file.
 LookupRegistry getLookupRegistry()
          Returns a LookupRegistry interface, which can be used by clients to lookup a remote reference from registry.
 DependableRegistry getRegistry()
          Returns a proxy for the dependable registry service.
 DependableRegistry getRegistry(java.rmi.server.RMIClientSocketFactory csf)
          Returns a proxy for the dependable registry service.
 

Method Detail

getRegistry

DependableRegistry getRegistry()
                               throws JgroupException,
                                      java.rmi.RemoteException
Returns a proxy for the dependable registry service.

Returns:
A proxy for the dependable registry service.
Throws:
java.rmi.RemoteException - Raised if the proxy could not be obtained.
ConfigurationException - Raised if there was a problem parsing the distributed system configuration file.
JgroupException

getRegistry

DependableRegistry getRegistry(java.rmi.server.RMIClientSocketFactory csf)
                               throws JgroupException,
                                      java.rmi.RemoteException
Returns a proxy for the dependable registry service. Communication with this remote registry will use the supplied RMIClientSocketFactory to create socket connections to the dependable registry on the distributed system and port.

Parameters:
csf - Client-side socket factory used to make connections to the dependable registry. If csf is null, then the default client-side socket factory will be used.
Returns:
A proxy for the dependable registry service.
Throws:
java.rmi.RemoteException - Raised if the proxy could not be obtained.
ConfigurationException - Raised if there was a problem parsing the distributed system configuration file.
JgroupException

createRegistry

DependableRegistry createRegistry()
                                  throws JgroupException,
                                         java.rmi.RemoteException
Creates and exports a dependable registry replica on the local host listening for incoming requests on an the port specified in the system configuration file.

Returns:
The newly created dependable registry replica.
Throws:
java.rmi.RemoteException - Raised if the registry could not be exported.
JgroupException - Raised if a registry instance could not be created.
ConfigurationException - Raised if there was a problem parsing the distributed system configuration file.

createRegistry

DependableRegistry createRegistry(java.rmi.server.RMIClientSocketFactory csf,
                                  java.rmi.server.RMIServerSocketFactory ssf)
                                  throws JgroupException,
                                         java.rmi.RemoteException
Creates and exports a dependable registry replica on the local host listening for incoming requests on an the port specified in the system configuration file.

The new instance of the dependable registry listens to incoming requests using a ServerSocket created from the supplied RMIServerSocketFactory. A client that receives a reference to this registry will then use a Socket created from the supplied RMIClientSocketFactory.

Parameters:
csf - Client-side Socket factory used to make connections to the registry.
ssf - Server-side ServerSocket factory used to accept connections to the registry.
Returns:
The newly created dependable registry replica.
Throws:
java.rmi.RemoteException - Raised if the registry could not be exported.
JgroupException - Raised if a registry instance could not be created.
ConfigurationException - Raised if there was a problem parsing the distributed system configuration file.

getLookupRegistry

LookupRegistry getLookupRegistry()
                                 throws JgroupException,
                                        java.rmi.RemoteException
Returns a LookupRegistry interface, which can be used by clients to lookup a remote reference from registry.

Returns:
LookupRegistry with methods to lookup remote ref from registry.
Throws:
JgroupException
java.rmi.RemoteException


Copyright © 1998-2006 The Jgroup/ARM development team. All Rights Reserved.