Class AckFirstGate

java.lang.Object
com.ultikits.ultitools.utils.AckFirstGate

final class AckFirstGate extends Object
Implements persist-id, acknowledge, then execute for ack-first requests. Result receipts are not recorded here; completed-link handlers own that step.
  • Field Details

    • LOGGER

      private static final Logger LOGGER
  • Constructor Details

    • AckFirstGate

      private AckFirstGate()
  • Method Details

    • handle

      static void handle(CloudRequest request, CloudChannel channel, DedupeLedger ledger, Runnable execute)
      Records and persists a new id under the shared ledger monitor, then releases the monitor before acknowledging and executing. Duplicates are acknowledged again but never executed. IOException during persistence is logged without exception text; acknowledgement and execution continue with in-memory dedupe. A refused send does not undo the recorded id or prevent first-time execution.
      Parameters:
      request - the validated ack-first request
      channel - the acknowledgement channel
      ledger - the shared session ledger and synchronization monitor
      execute - the first-delivery action, invoked outside the ledger monitor