org.softamis.cluster4spring.rmi
Class RmiServiceExporter
java.lang.Object
org.springframework.remoting.support.RemoteExporter
org.springframework.remoting.support.RemoteInvocationBasedExporter
org.softamis.cluster4spring.rmi.AbstractRmiServiceExporter
org.softamis.cluster4spring.rmi.RmiServiceExporter
- All Implemented Interfaces:
- AutoDiscoveredServiceExporter, org.springframework.beans.factory.BeanClassLoaderAware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean
public class RmiServiceExporter
- extends AbstractRmiServiceExporter
RMI exporter that exposes the specified service as RMI object with the specified
name. Such services can be accessed via plain RMI or via RmiProxyFactoryBean.
Also supports exposing any non-RMI service via RMI invokers, to be accessed via
RmiClientInterceptor/RmiProxyFactoryBean's automatic detection of such invokers.
With an RMI invoker, RMI communication works on the RmiInvocationHandler
level, needing only one stub for any service. Service interfaces do not have to
extend java.rmi.Remote or throw RemoteException on all methods, but in and out
parameters have to be serializable.
- Author:
- Andrew Sazonov
Field Summary |
protected static org.apache.commons.logging.Log |
fLog
|
Fields inherited from class org.softamis.cluster4spring.rmi.AbstractRmiServiceExporter |
ATTRIBUTE_OWN_PROXY_SERVICE_NAME, fAllowsAutoDiscovering, fBeanFactory, fClientSocketFactory, fExportedObject, fInterceptorNames, fRegistry, fRegistryClientSocketFactory, fRegistryHost, fRegistryPort, fRegistryServerSocketFactory, fRemoteInvocationTraceInterceptor, fServerSocketFactory, fServiceGroup, fServiceName, fServicePort |
Fields inherited from class org.springframework.remoting.support.RemoteExporter |
logger |
Method Summary |
java.util.List<java.lang.String> |
provideExportedServiceURLs()
Returns list of URLs that could be used to locate service |
Methods inherited from class org.softamis.cluster4spring.rmi.AbstractRmiServiceExporter |
afterPropertiesSet, createDefaultRemoteInvocationTraceInterceptor, createServiceUrl, destroy, exportObject, getInterceptorNames, getObjectToExport, getProxyForService, getRegistry, getRegistry, getRegistry, getRegistry, getRegistryHost, getRegistryPort, getServiceGroup, getServiceName, getServicePort, isAllowsAutoDiscovering, obtainRemoteInvocationTraceInterceptor, prepare, prepareRegistry, setAllowsAutoDiscovering, setBeanFactory, setClientSocketFactory, setInterceptorNames, setRegistry, setRegistryClientSocketFactory, setRegistryHost, setRegistryPort, setRegistryServerSocketFactory, setRemoteInvocationTraceInterceptor, setServerSocketFactory, setServiceGroup, setServiceName, setServicePort, testRegistry, unexportObjectSilently, unexportServiceObject |
Methods inherited from class org.springframework.remoting.support.RemoteInvocationBasedExporter |
getRemoteInvocationExecutor, invoke, invokeAndCreateResult, setRemoteInvocationExecutor |
Methods inherited from class org.springframework.remoting.support.RemoteExporter |
checkService, checkServiceInterface, getExporterName, getService, getServiceInterface, isRegisterTraceInterceptor, setBeanClassLoader, setRegisterTraceInterceptor, setService, setServiceInterface |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
fLog
protected static final org.apache.commons.logging.Log fLog
RmiServiceExporter
public RmiServiceExporter()
provideExportedServiceURLs
public java.util.List<java.lang.String> provideExportedServiceURLs()
- Description copied from interface:
AutoDiscoveredServiceExporter
- Returns list of URLs that could be used to locate service
- Returns:
- list of service URL's