java.lang.Object | |||||
↳ | org.springframework.remoting.support.RemotingSupport | ||||
↳ | org.springframework.remoting.support.RemoteAccessor | ||||
↳ | org.springframework.remoting.support.UrlBasedRemoteAccessor | ||||
↳ | org.springframework.remoting.support.RemoteInvocationBasedAccessor | ||||
↳ | org.springframework.remoting.httpinvoker.HttpInvokerClientInterceptor |
Known Direct Subclasses |
org.aopalliance.intercept.MethodInterceptor for accessing an HTTP invoker service. The service URL must be an HTTP URL exposing an HTTP invoker service.
Serializes remote invocation objects and deserializes remote invocation result objects. Uses Java serialization just like RMI, but provides the same ease of setup as Caucho's HTTP-based Hessian and Burlap protocols.
HTTP invoker is a very extensible and customizable protocol.
It supports the RemoteInvocationFactory mechanism, like RMI invoker,
allowing to include additional invocation attributes (for example,
a security context). Furthermore, it allows to customize request
execution via the HttpInvokerRequestExecutor
strategy.
Can use the JDK's java.rmi.server.RMIClassLoader to load
classes from a given codebase
, performing
on-demand dynamic code download from a remote location. The codebase
can consist of multiple URLs, separated by spaces. Note that
RMIClassLoader requires a SecurityManager to be set, analogous to
when using dynamic class download with standard RMI!
(See the RMI documentation for details.)
[Expand]
Inherited Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.springframework.remoting.support.RemotingSupport
|
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Invoked by a BeanFactory after it has set all bean properties supplied
(and satisfied BeanFactoryAware and ApplicationContextAware).
| |||||||||||
Return the codebase URL to download classes from if not found locally.
| |||||||||||
Return the HttpInvokerRequestExecutor used by this remote accessor.
| |||||||||||
Set the codebase URL to download classes from if not found locally.
| |||||||||||
Set the HttpInvokerRequestExecutor implementation to use for executing
remote invocations.
|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Convert the given HTTP invoker access exception to an appropriate
Spring RemoteAccessException.
| |||||||||||
Execute the given remote invocation via the HttpInvokerRequestExecutor.
| |||||||||||
Execute the given remote invocation via the HttpInvokerRequestExecutor.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.springframework.remoting.support.RemoteInvocationBasedAccessor
| |||||||||||
From class
org.springframework.remoting.support.UrlBasedRemoteAccessor
| |||||||||||
From class
org.springframework.remoting.support.RemoteAccessor
| |||||||||||
From class
org.springframework.remoting.support.RemotingSupport
| |||||||||||
From class
java.lang.Object
| |||||||||||
From interface
org.springframework.beans.factory.BeanClassLoaderAware
| |||||||||||
From interface
org.springframework.beans.factory.InitializingBean
| |||||||||||
From interface
org.springframework.remoting.httpinvoker.HttpInvokerClientConfiguration
|
Invoked by a BeanFactory after it has set all bean properties supplied (and satisfied BeanFactoryAware and ApplicationContextAware).
This method allows the bean instance to perform initialization only possible when all bean properties have been set and to throw an exception in the event of misconfiguration.
Return the codebase URL to download classes from if not found locally.
null
if noneReturn the HttpInvokerRequestExecutor used by this remote accessor.
Creates a default SimpleHttpInvokerRequestExecutor if no executor has been initialized already.
Set the codebase URL to download classes from if not found locally. Can consists of multiple URLs, separated by spaces.
Follows RMI's codebase conventions for dynamic class download. In contrast to RMI, where the server determines the URL for class download (via the "java.rmi.server.codebase" system property), it's the client that determines the codebase URL here. The server will usually be the same as for the service URL, just pointing to a different path there.
setServiceUrl(String)
CodebaseAwareObjectInputStream
Set the HttpInvokerRequestExecutor implementation to use for executing remote invocations.
Default is SimpleHttpInvokerRequestExecutor
. Alternatively,
consider using CommonsHttpInvokerRequestExecutor
for more
sophisticated needs.
Convert the given HTTP invoker access exception to an appropriate Spring RemoteAccessException.
ex | the exception to convert |
---|
Execute the given remote invocation via the HttpInvokerRequestExecutor.
Can be overridden in subclasses to pass a different configuration object to the executor. Alternatively, add further configuration properties in a subclass of this accessor: By default, the accessor passed itself as configuration object to the executor.
invocation | the RemoteInvocation to execute |
---|
IOException | if thrown by I/O operations |
---|---|
ClassNotFoundException | if thrown during deserialization |
Exception | in case of general errors |
Execute the given remote invocation via the HttpInvokerRequestExecutor.
This implementation delegates to executeRequest(RemoteInvocation)
.
Can be overridden to react to the specific original MethodInvocation.
invocation | the RemoteInvocation to execute |
---|---|
originalInvocation | the original MethodInvocation (can e.g. be cast to the ProxyMethodInvocation interface for accessing user attributes) |
Exception | in case of errors |
---|