Class ModelBatchScope

java.lang.Object
io.fluxzero.sdk.modeling.ModelBatchScope

public final class ModelBatchScope extends Object
One message-batch-local model scope for read-your-writes, exact dependencies and commit release. Pending values stay visible only at their namespace, routing segment and message position. Reading one registers its producing entry as a predecessor; successful or failed entries immediately yield to authoritative storage.
  • Method Details

    • commitCurrent

      public static CompletableFuture<Void> commitCurrent()
      Releases the pending Model commit attached to the current message and returns its existing completion. A context without pending changes completes immediately and never opens transport.
    • overlayCurrent

      public static <T> Entity<T> overlayCurrent(String namespace, String requestedId, Class<T> requestedType, Entity<T> durable)
      Overlays a durable direct load with the newest pending model or alias visible to the current message.
    • overlayCurrent

      public static CommitAttempt overlayCurrent(String namespace, CommitAttempt durable)
      Overlays pending exact values without changing the durable context's pinned state boundary.
    • currentValues

      public static Map<String, Entity<?>> currentValues(String namespace)
      Returns pending exact values visible to the current message, in message order.
    • currentValue

      public static Entity<?> currentValue(String namespace, String modelId)
      Returns one pending exact value; aliases are deliberately not resolved.
    • currentValues

      public static Map<String,Object> currentValues(String namespace, MutationPlan.Resolution resolution)
      Returns the pending values needed to reconstruct one resolved context, including ancestor dependencies.