Class QueryBasedCreationData
- java.lang.Object
-
- de.hybris.platform.processing.distributed.simple.data.SimpleAbstractDistributedProcessCreationData
-
- de.hybris.platform.processing.distributed.simple.data.QueryBasedCreationData
-
- All Implemented Interfaces:
ProcessCreationData
public class QueryBasedCreationData extends SimpleAbstractDistributedProcessCreationData
Process creation data which is based on Flexible Search Query. By default it queries for PKs of an Item and only PKs will be on a result list. According to the batch size a List of resulting PKs will be available as a context data for individual batch processing. More complex, multi-value queries are also supported but result class list must be provided. Keep in mind that result must be serializable since it is stored in a BLOB field of a Batch later on.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classQueryBasedCreationData.Builderstatic interfaceQueryBasedCreationData.QueryHook
-
Field Summary
-
Fields inherited from class de.hybris.platform.processing.distributed.simple.data.SimpleAbstractDistributedProcessCreationData
batchSize, DEFAULT_BATCH_SIZE, DEFAULT_NUM_RETRIES, handlerId, nodeGroup, numOfRetries, processId, processModelClass, scriptCode
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedQueryBasedCreationData(java.lang.String handlerId, java.lang.String processId, java.lang.String nodeGroup, java.lang.Integer batchSize, java.lang.Integer numOfRetries, java.lang.String query, java.util.Map<java.lang.String,java.lang.Object> queryParams, java.util.List<java.lang.Class<?>> resultClasses, FlexibleSearchQuery flexibleSearchQuery, java.lang.String scriptCode, boolean useDatabasePaging, QueryBasedCreationData.QueryHook beforeQueryHook, java.lang.Class<? extends SimpleDistributedProcessModel> processModelClass)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static QueryBasedCreationData.Builderbuilder()java.util.stream.Stream<? extends SimpleBatchCreationData>initialBatches()Responsible for returning stream for creating initial batches used by distributed process.-
Methods inherited from class de.hybris.platform.processing.distributed.simple.data.SimpleAbstractDistributedProcessCreationData
getBatchSize, getHandlerBeanId, getNodeGroup, getNumOfRetries, getProcessId, getProcessModelClass, getScriptCode
-
-
-
-
Constructor Detail
-
QueryBasedCreationData
protected QueryBasedCreationData(java.lang.String handlerId, java.lang.String processId, java.lang.String nodeGroup, java.lang.Integer batchSize, java.lang.Integer numOfRetries, java.lang.String query, java.util.Map<java.lang.String,java.lang.Object> queryParams, java.util.List<java.lang.Class<?>> resultClasses, FlexibleSearchQuery flexibleSearchQuery, java.lang.String scriptCode, boolean useDatabasePaging, QueryBasedCreationData.QueryHook beforeQueryHook, java.lang.Class<? extends SimpleDistributedProcessModel> processModelClass)
-
-
Method Detail
-
initialBatches
public java.util.stream.Stream<? extends SimpleBatchCreationData> initialBatches()
Description copied from interface:ProcessCreationDataResponsible for returning stream for creating initial batches used by distributed process.- Specified by:
initialBatchesin interfaceProcessCreationData- Specified by:
initialBatchesin classSimpleAbstractDistributedProcessCreationData- Returns:
- Stream of batch data
-
builder
public static QueryBasedCreationData.Builder builder()
-
-