Class AckUtils

java.lang.Object
org.springframework.integration.acks.AckUtils

public final class AckUtils
extends java.lang.Object
Utility methods for acting on AcknowledgmentCallback headers.
Since:
5.0.1
  • Method Details

    • autoAck

      public static void autoAck​(@Nullable AcknowledgmentCallback ackCallback)
      ACCEPT an AcknowledgmentCallback if it's not null, supports auto ack and is not already ack'd.
      Parameters:
      ackCallback - the callback.
    • autoNack

      public static void autoNack​(@Nullable AcknowledgmentCallback ackCallback)
      REJECT an AcknowledgmentCallback if it's not null, supports auto ack and is not already ack'd.
      Parameters:
      ackCallback - the callback.
    • accept

      public static void accept​(@Nullable AcknowledgmentCallback ackCallback)
      ACCEPT the associated message if the callback is not null.
      Parameters:
      ackCallback - the callback.
    • reject

      public static void reject​(@Nullable AcknowledgmentCallback ackCallback)
      REJECT the associated message if the callback is not null.
      Parameters:
      ackCallback - the callback.
    • requeue

      public static void requeue​(@Nullable AcknowledgmentCallback ackCallback)
      REQUEUE the associated message if the callback is not null.
      Parameters:
      ackCallback - the callback.