Class MultiTakeReceiveOperationHandler
java.lang.Object
org.openspaces.events.polling.receive.AbstractNonBlockingReceiveOperationHandler
org.openspaces.events.polling.receive.AbstractMemoryOnlySearchReceiveOperationHandler
org.openspaces.events.polling.receive.AbstractFifoGroupingReceiveOperationHandler
org.openspaces.events.polling.receive.MultiTakeReceiveOperationHandler
- All Implemented Interfaces:
ReceiveOperationHandler
First tries and perform a
GigaSpace.takeMultiple(Object, int, TakeModifiers)
using the provided template, the configured maxEntries (defaults to 50) and the
configured fifoGroups (default to false). If no values are returned, will perform
a blocking take operation using GigaSpace.take(Object, long, TakeModifiers).
- Author:
- kimchy
-
Field Summary
Fields inherited from class org.openspaces.events.polling.receive.AbstractFifoGroupingReceiveOperationHandler
useFifoGroupingFields inherited from class org.openspaces.events.polling.receive.AbstractMemoryOnlySearchReceiveOperationHandler
useMemoryOnlySearchFields inherited from class org.openspaces.events.polling.receive.AbstractNonBlockingReceiveOperationHandler
nonBlocking, nonBlockingFactor -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected ObjectdoReceiveBlocking(Object template, GigaSpace gigaSpace, long receiveTimeout) First tries and perform aGigaSpace.takeMultiple(Object, int, TakeModifiers)using the provided template, the configured maxEntries (defaults to50) and the configured fifoGroups (default tofalse).protected ObjectdoReceiveNonBlocking(Object template, GigaSpace gigaSpace) Performs a non blockingGigaSpace.takeMultiple(Object, int, TakeModifiers)using the provided template, the configured maxEntries (defaults to50) and the configured fifoGroups (default tofalse).voidsetMaxEntries(int maxEntries) Sets the max entries the initial take multiple operation will perform.toString()Methods inherited from class org.openspaces.events.polling.receive.AbstractFifoGroupingReceiveOperationHandler
isUseFifoGrouping, setUseFifoGroupingMethods inherited from class org.openspaces.events.polling.receive.AbstractMemoryOnlySearchReceiveOperationHandler
isUseMemoryOnlySearch, setUseMemoryOnlySearchMethods inherited from class org.openspaces.events.polling.receive.AbstractNonBlockingReceiveOperationHandler
receive, setNonBlocking, setNonBlockingFactor
-
Constructor Details
-
MultiTakeReceiveOperationHandler
public MultiTakeReceiveOperationHandler()
-
-
Method Details
-
setMaxEntries
public void setMaxEntries(int maxEntries) Sets the max entries the initial take multiple operation will perform. -
doReceiveBlocking
protected Object doReceiveBlocking(Object template, GigaSpace gigaSpace, long receiveTimeout) throws org.springframework.dao.DataAccessException First tries and perform aGigaSpace.takeMultiple(Object, int, TakeModifiers)using the provided template, the configured maxEntries (defaults to50) and the configured fifoGroups (default tofalse). If no values are returned, will perform a blocking take operation usingGigaSpace.take(Object, long, TakeModifiers).- Specified by:
doReceiveBlockingin classAbstractNonBlockingReceiveOperationHandler- Throws:
org.springframework.dao.DataAccessException
-
doReceiveNonBlocking
protected Object doReceiveNonBlocking(Object template, GigaSpace gigaSpace) throws org.springframework.dao.DataAccessException Performs a non blockingGigaSpace.takeMultiple(Object, int, TakeModifiers)using the provided template, the configured maxEntries (defaults to50) and the configured fifoGroups (default tofalse).- Specified by:
doReceiveNonBlockingin classAbstractNonBlockingReceiveOperationHandler- Throws:
org.springframework.dao.DataAccessException
-
toString
-