Interface EntityActionDecomposer<A extends Executable>


@Incubating public interface EntityActionDecomposer<A extends Executable>

Handles decomposing for a single action type (delegation).

Decomposes actions into individual table operations. Grouping and batching of operations happens later in FlushCoordinator.

Post-execution callbacks are attached directly to Flush operations and execute inline as operations complete, rather than being registered globally.

Entity decomposers are created by the entity persister. State-management strategies may still alter the mutation plan by supplying an EntityMutationPlanContributor. The decomposer owns the common action lifecycle and operation ordering, while the contributor may replace the table mutation plan for logical update/delete actions such as soft-delete or temporal row versioning.

Since:
8.0
See Also:
  • Method Details

    • decompose

      void decompose(A action, int ordinalBase, SharedSessionContractImplementor session, DecompositionContext decompositionContext, Consumer<FlushOperation> operationConsumer)
      Decompose the action into its constituent table operations.
      Parameters:
      action - The action to decompose
      ordinalBase - Defines a "slot range" which is used to help order operations later. Use small offsets from this base for each operation.
      session - The session from which this request originates.
      decompositionContext - The decomposition context tracking entities being inserted (might be null)
      operationConsumer - Consumer for any table operations produced