Package | Description |
---|---|
org.xins.client |
XINS client framework.
|
org.xins.common.http |
HTTP-related utility classes.
|
org.xins.common.service |
Service calling classes, supporting load-balancing and failover.
|
Modifier and Type | Class and Description |
---|---|
class |
XINSCallRequest
Abstraction of a XINS request.
|
Modifier and Type | Method and Description |
---|---|
protected CallResult |
XINSServiceCaller.createCallResult(CallRequest request,
TargetDescriptor succeededTarget,
long duration,
List<CallException> exceptions,
Object result)
Constructs an appropriate
CallResult object for a
successful call attempt. |
Object |
XINSServiceCaller.doCallImpl(CallRequest request,
CallConfig callConfig,
TargetDescriptor target)
Executes the specified request on the given target.
|
protected boolean |
XINSServiceCaller.shouldFailOver(CallRequest request,
CallConfig callConfig,
List<CallException> exceptions)
Determines whether a call should fail-over to the next selected target
based on a request, call configuration and exception list.
|
Modifier and Type | Class and Description |
---|---|
class |
HTTPCallRequest
A request towards an HTTP service.
|
Modifier and Type | Method and Description |
---|---|
protected CallResult |
HTTPServiceCaller.createCallResult(CallRequest request,
TargetDescriptor succeededTarget,
long duration,
List<CallException> exceptions,
Object result)
Constructs an appropriate
CallResult object for a
successful call attempt. |
Object |
HTTPServiceCaller.doCallImpl(CallRequest request,
CallConfig callConfig,
TargetDescriptor target)
Executes a request towards the specified target.
|
protected boolean |
HTTPServiceCaller.shouldFailOver(CallRequest request,
CallConfig callConfig,
List<CallException> exceptions)
Determines whether a call should fail-over to the next selected target
based on a request, call configuration and exception list.
|
Modifier and Type | Method and Description |
---|---|
CallRequest |
CallResult.getRequest()
Returns the call request.
|
CallRequest |
CallException.getRequest()
Returns the original request.
|
Modifier and Type | Method and Description |
---|---|
protected abstract CallResult |
ServiceCaller.createCallResult(CallRequest request,
TargetDescriptor succeededTarget,
long duration,
List<CallException> exceptions,
Object result)
Constructs an appropriate
CallResult object for a
successful call attempt. |
protected CallResult |
ServiceCaller.doCall(CallRequest request,
CallConfig callConfig)
Attempts to execute the specified call request on one of the target
services, with the specified call configuration.
|
abstract Object |
ServiceCaller.doCallImpl(CallRequest request,
CallConfig callConfig,
TargetDescriptor target)
Calls the specified target using the specified subject.
|
protected boolean |
ServiceCaller.shouldFailOver(CallRequest request,
CallConfig callConfig,
List<CallException> exceptions)
Determines whether a call should fail-over to the next selected target
based on a request, call configuration and exception list.
|
Constructor and Description |
---|
CallException(String shortReason,
CallRequest request,
TargetDescriptor target,
long duration,
String detail,
Throwable cause)
Constructs a new
CallException based on a short reason, the
original request, target called, call duration, detail message and cause
exception. |
CallResult(CallRequest request,
TargetDescriptor succeededTarget,
long duration,
List<CallException> exceptions)
Constructs a new
CallResult object. |
ConnectionRefusedCallException(CallRequest request,
TargetDescriptor target,
long duration)
Constructs a new
ConnectionRefusedCallException . |
ConnectionTimeOutCallException(CallRequest request,
TargetDescriptor target,
long duration)
Constructs a new
ConnectionTimeOutCallException . |
IOCallException(CallRequest request,
TargetDescriptor target,
long duration,
IOException ioException)
Constructs a new
IOCallException . |
NoRouteToHostCallException(CallRequest request,
TargetDescriptor target,
long duration)
Constructs a new
NoRouteToHostCallException . |
SocketTimeOutCallException(CallRequest request,
TargetDescriptor target,
long duration)
Constructs a new
SocketTimeOutCallException . |
TotalTimeOutCallException(CallRequest request,
TargetDescriptor target,
long duration)
Constructs a new
TotalTimeOutCallException . |
UnexpectedExceptionCallException(CallRequest request,
TargetDescriptor target,
long duration,
String detail,
Throwable cause)
Constructs a new
UnexpectedExceptionCallException . |
UnknownHostCallException(CallRequest request,
TargetDescriptor target,
long duration)
Constructs a new
UnknownHostCallException . |
See http://www.xins.org/.