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 serverThread
for 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 void
callInvokerOnRawArgs(ome.api.ServiceInterface service, IceMethodInvoker invoker, java.lang.Object __cb, Ice.Current __current, java.lang.Object... args)
Uses the givenIceMethodInvoker
to make the method call.void
callInvokerWithMappedArgs(ome.api.ServiceInterface service, IceMethodInvoker invoker, IceMapper mapper, java.lang.Object __cb, Ice.Current __current, java.lang.Object... args)
Passes the given arguments toIceMethodInvoker
with the assumption that all conversion from omero.* to ome.* has taken place.void
runnableCall(Ice.Current __current, Task runnable)
<R> void
safeRunnableCall(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:BlitzExecutor
Uses the givenIceMethodInvoker
to 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:BlitzExecutor
Passes the given arguments toIceMethodInvoker
with the assumption that all conversion from omero.* to ome.* has taken place. Similarly, theIceMapper
instance 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)
-
-