Class MessageDeliveryErrorHandlerBuilder

    • Constructor Detail

      • MessageDeliveryErrorHandlerBuilder

        public MessageDeliveryErrorHandlerBuilder()
    • Method Detail

      • alwaysRetryOn

        @SafeVarargs
        public final MessageDeliveryErrorHandlerBuilder alwaysRetryOn​(Class<? extends Exception>... exceptions)
        The resulting MessageDeliveryErrorHandler will keep retrying message redelivery no matter how many times message handling experiences an exception for in the list of exceptions.
        It will first attempt to match directly on Exception class, next it will attempt to match on hierarchy (i.e. a concrete error which is a subtype of an Exception found in the exceptions will also match)
        Parameters:
        exceptions - the exceptions where message redelivery will be continued no matter how many times this exception occurs
        Returns:
        this builder instance
      • alwaysRetryOn

        public MessageDeliveryErrorHandlerBuilder alwaysRetryOn​(List<Class<? extends Exception>> exceptions)
        The resulting MessageDeliveryErrorHandler will keep retrying message redelivery no matter how many times message handling experiences an exception for in the list of exceptions.
        It will first attempt to match directly on Exception class, next it will attempt to match on hierarchy (i.e. a concrete error which is a subtype of an Exception found in the exceptions will also match)
        Parameters:
        exceptions - the exceptions where message redelivery will be continued no matter how many times this exception occurs
        Returns:
        this builder instance
      • stopRedeliveryOn

        @SafeVarargs
        public final MessageDeliveryErrorHandlerBuilder stopRedeliveryOn​(Class<? extends Exception>... exceptions)
        The resulting MessageDeliveryErrorHandler will stop message redelivery in case message handling experiences an exception for in the list of exceptions.
        It will first attempt to match directly on Exception class, next it will attempt to match on hierarchy (i.e. a concrete error which is a subtype of an Exception found in the exceptions will also match)
        Parameters:
        exceptions - the exceptions where message redelivery will be stopped and the Message will be instantly marked as a Poison-Message/Dead-Letter-Message
        Returns:
        this builder instance
      • stopRedeliveryOn

        public MessageDeliveryErrorHandlerBuilder stopRedeliveryOn​(List<Class<? extends Exception>> exceptions)
        The resulting MessageDeliveryErrorHandler will stop message redelivery in case message handling experiences an exception for in the list of exceptions.
        It will first attempt to match directly on Exception class, next it will attempt to match on hierarchy (i.e. a concrete error which is a subtype of an Exception found in the exceptions will also match)
        Parameters:
        exceptions - the exceptions where message redelivery will be stopped and the Message will be instantly marked as a Poison-Message/Dead-Letter-Message
        Returns:
        this builder instance