Interface PojoIndexingQueueEventProcessingPlan
-
public interface PojoIndexingQueueEventProcessingPlan
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidappend(String entityName, String serializedId, PojoIndexingQueueEventPayload payload)Appends an event to the plan, received from aPojoIndexingQueueEventSendingPlan.<R> CompletableFuture<MultiEntityOperationExecutionReport<R>>executeAndReport(EntityReferenceFactory<R> entityReferenceFactory)Writes all pending changes to the index now, and clears the plan so that it can be re-used.ObjecttoIdentifier(String entityName, String serializedId)Convert the serialized id to the original identifier.<I> StringtoSerializedId(String entityName, I identifier)Convert the identifier to its serialized form.
-
-
-
Method Detail
-
append
void append(String entityName, String serializedId, PojoIndexingQueueEventPayload payload)
Appends an event to the plan, received from aPojoIndexingQueueEventSendingPlan.- Parameters:
entityName- The name of the entity type.serializedId- The serialized entity identifier.payload- The payload as passed to the sending plan.- See Also:
PojoIndexingQueueEventSendingPlan.append(String, Object, String, PojoIndexingQueueEventPayload)
-
executeAndReport
<R> CompletableFuture<MultiEntityOperationExecutionReport<R>> executeAndReport(EntityReferenceFactory<R> entityReferenceFactory)
Writes all pending changes to the index now, and clears the plan so that it can be re-used.- Type Parameters:
R- The type of entity references in the returned execution report.- Parameters:
entityReferenceFactory- A factory for entity references in the returned execution report.- Returns:
- A
CompletableFuturethat will be completed with an execution report when all the works are complete.
-
toSerializedId
<I> String toSerializedId(String entityName, I identifier)
Convert the identifier to its serialized form. The identifier type must be the one used by the entity having nameentityName.- Type Parameters:
I- The type of the identifier of the entity.- Parameters:
entityName- The name of the entity.identifier- The provided identifier.- Returns:
- The serialized form of the provided identifier.
-
-