Class PrepareBulkAtomicUpdate
- java.lang.Object
-
- fr.gouv.vitam.worker.core.handler.ActionHandler
-
- fr.gouv.vitam.worker.core.plugin.bulkatomicupdate.PrepareBulkAtomicUpdate
-
- All Implemented Interfaces:
VitamAutoCloseable
,WorkerAction
,java.lang.AutoCloseable
public class PrepareBulkAtomicUpdate extends ActionHandler
Prepare execute execute each query in query.json. Queries are executed in bulks, each bulk is run concurrently is a thread pool. Queries are updated with access contract restrictions. Query projection is set to "_id" field only. Queries with internal fields are blocked ==> Report WARNING in batch report Queries result size is limited to 2. - If a single entry is found ==> Happy path, we append unitId to distribution file - No entries found ==> Report WARNING in batch report (no unit found) - 2 entries found ==> Report WARNING in batch report (multiple units found) Report entries are buffered and sent as bulks to BatchReport (to reduce IOs to BatchReport) Distribution file entries are buffered and written to disk in bulks (to reduce IO contention)
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
PREPARE_BULK_ATOMIC_UPDATE_UNIT_LIST_PLUGIN_NAME
-
Constructor Summary
Constructors Constructor Description PrepareBulkAtomicUpdate()
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ItemStatus
execute(WorkerParameters param, HandlerIO handler)
Execute an action-
Methods inherited from class fr.gouv.vitam.worker.core.handler.ActionHandler
checkMandatoryParameters, close, updateDetailItemStatus
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface fr.gouv.vitam.worker.core.api.WorkerAction
checkMandatoryIOParameter, executeList
-
-
-
-
Field Detail
-
PREPARE_BULK_ATOMIC_UPDATE_UNIT_LIST_PLUGIN_NAME
public static final java.lang.String PREPARE_BULK_ATOMIC_UPDATE_UNIT_LIST_PLUGIN_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
execute
public ItemStatus execute(WorkerParameters param, HandlerIO handler) throws ProcessingException
Description copied from interface:WorkerAction
Execute an action- Parameters:
param
-WorkerParameters
handler
- the handlerIo- Returns:
- CompositeItemStatus:response contains a list of functional message and status code
- Throws:
ProcessingException
- if an error is encountered when executing the action
-
-