Class IntelligentProxyInterceptor
- java.lang.Object
 - 
- jadex.bridge.service.component.interceptors.AbstractApplicableInterceptor
 - 
- jadex.bridge.service.component.interceptors.IntelligentProxyInterceptor
 
 
 
- 
- All Implemented Interfaces:
 IServiceInvocationInterceptor
public class IntelligentProxyInterceptor extends AbstractApplicableInterceptor
Interceptor for realizing intelligent proxies. These proxies are used e.g. by a global service pool to dynamically redirect service calls. 
- 
- 
Field Summary
Fields Modifier and Type Field Description protected IExternalAccesseaThe external access.protected static ITargetResolverNULLprotected IServiceIdentifiersidThe service identifier.protected ITargetResolvertrThe target resolver.protected longwtoThe worker timeout. 
- 
Constructor Summary
Constructors Constructor Description IntelligentProxyInterceptor(IExternalAccess ea, IServiceIdentifier sid)Create a new invocation handler. 
- 
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description IFuture<java.lang.Void>execute(ServiceInvocationContext sic)Execute the interceptor.protected ITargetResolvergetTargetResolver(ServiceInvocationContext sic)Get the target resolver.protected static java.lang.ExceptionhandleException(java.lang.Exception e)protected IFuture<java.lang.Void>invoke(IServiceIdentifier broken, ServiceInvocationContext sic, int maxretries, int cnt)static IFuture<java.lang.Object>invoke(IServiceIdentifier broken, ServiceInvocationContext sic, IServiceIdentifier sid, IExternalAccess ea, ITargetResolver tr, int maxretries, int cnt)static booleanisRedirectable(ServiceInvocationContext sic)- 
Methods inherited from class jadex.bridge.service.component.interceptors.AbstractApplicableInterceptor
isApplicable 
 - 
 
 - 
 
- 
- 
Field Detail
- 
ea
protected IExternalAccess ea
The external access. 
- 
sid
protected IServiceIdentifier sid
The service identifier. 
- 
tr
protected ITargetResolver tr
The target resolver. 
- 
wto
protected long wto
The worker timeout. 
- 
NULL
protected static final ITargetResolver NULL
 
 - 
 
- 
Constructor Detail
- 
IntelligentProxyInterceptor
public IntelligentProxyInterceptor(IExternalAccess ea, IServiceIdentifier sid)
Create a new invocation handler. 
 - 
 
- 
Method Detail
- 
execute
public IFuture<java.lang.Void> execute(ServiceInvocationContext sic)
Execute the interceptor.- Parameters:
 context- The invocation context.
 
- 
invoke
protected IFuture<java.lang.Void> invoke(IServiceIdentifier broken, ServiceInvocationContext sic, int maxretries, int cnt)
 
- 
handleException
protected static java.lang.Exception handleException(java.lang.Exception e)
 
- 
getTargetResolver
protected ITargetResolver getTargetResolver(ServiceInvocationContext sic)
Get the target resolver.- Returns:
 - The target resolver.
 
 
- 
isRedirectable
public static boolean isRedirectable(ServiceInvocationContext sic)
 
- 
invoke
public static IFuture<java.lang.Object> invoke(IServiceIdentifier broken, ServiceInvocationContext sic, IServiceIdentifier sid, IExternalAccess ea, ITargetResolver tr, int maxretries, int cnt)
 
 - 
 
 -