Package ome.services.throttling
Class InThreadThrottlingStrategy
- java.lang.Object
-
- ome.services.throttling.AbstractThrottlingStrategy
-
- ome.services.throttling.InThreadThrottlingStrategy
-
- All Implemented Interfaces:
java.util.EventListener,BlitzExecutor,ThrottlingStrategy,org.springframework.beans.factory.Aware,org.springframework.context.ApplicationContextAware,org.springframework.context.ApplicationListener
public class InThreadThrottlingStrategy extends AbstractThrottlingStrategy
Throttling implementation which uses the calling serverThreadfor execution. This mimics the behavior of the pre-AMD blitz.
-
-
Field Summary
-
Fields inherited from class ome.services.throttling.AbstractThrottlingStrategy
ctx
-
-
Constructor Summary
Constructors Constructor Description InThreadThrottlingStrategy(ome.security.basic.CurrentDetails cd)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcallInvokerOnRawArgs(ome.api.ServiceInterface service, IceMethodInvoker invoker, java.lang.Object __cb, Ice.Current __current, java.lang.Object... args)Uses the givenIceMethodInvokerto make the method call.voidcallInvokerWithMappedArgs(ome.api.ServiceInterface service, IceMethodInvoker invoker, IceMapper mapper, java.lang.Object __cb, Ice.Current __current, java.lang.Object... args)Passes the given arguments toIceMethodInvokerwith the assumption that all conversion from omero.* to ome.* has taken place.voidrunnableCall(Ice.Current __current, Task runnable)<R> voidsafeRunnableCall(Ice.Current __current, java.lang.Object __cb, boolean isVoid, java.util.concurrent.Callable<R> callable)-
Methods inherited from class ome.services.throttling.AbstractThrottlingStrategy
onApplicationEvent, setApplicationContext
-
-
-
-
Method Detail
-
callInvokerOnRawArgs
public void callInvokerOnRawArgs(ome.api.ServiceInterface service, IceMethodInvoker invoker, java.lang.Object __cb, Ice.Current __current, java.lang.Object... args)Description copied from interface:BlitzExecutorUses the givenIceMethodInvokerto make the method call. All arguments are passed directly into the invoker, and the return value from the invoker is passed to the user.
-
callInvokerWithMappedArgs
public void callInvokerWithMappedArgs(ome.api.ServiceInterface service, IceMethodInvoker invoker, IceMapper mapper, java.lang.Object __cb, Ice.Current __current, java.lang.Object... args)Description copied from interface:BlitzExecutorPasses the given arguments toIceMethodInvokerwith the assumption that all conversion from omero.* to ome.* has taken place. Similarly, theIceMapperinstance will be used to map the return value from ome.* to omero.*.
-
safeRunnableCall
public <R> void safeRunnableCall(Ice.Current __current, java.lang.Object __cb, boolean isVoid, java.util.concurrent.Callable<R> callable)
-
runnableCall
public void runnableCall(Ice.Current __current, Task runnable)
-
-