@ProviderType
public interface MessageAcknowledgementConfiguration
Modifier and Type | Interface and Description |
---|---|
static class |
MessageAcknowledgementConfiguration.Outcome
Represents the type for supported message settlement outcome
|
Modifier and Type | Method and Description |
---|---|
MessageAcknowledgementConfiguration |
withMessageAutoAcknowledgement()
Enables support for message Auto-Acknowledgement (auto-ack) for persistent message receiver.
|
MessageAcknowledgementConfiguration |
withMessageClientAcknowledgement()
Enables support for client message acknowledgement on persistent message receiver.
|
MessageAcknowledgementConfiguration |
withRequiredMessageClientOutcomeOperationSupport(MessageAcknowledgementConfiguration.Outcome... requiredOutcomes)
Enables required support for all specified settlement options
|
MessageAcknowledgementConfiguration withMessageAutoAcknowledgement()
Note:
- For messages received on callback based methods, auto-ack is performed when the message-processing callback method finishes without an error. This means that if the message-processing callback method decides to process messages using another thread, message acknowledgement may be performed before another thread finishes, and any exceptions thrown in the other thread won't be considered.
- For messages received on a blocking receive methods (without callback), auto-ack is
performed immediately when the message is passed to the receive (..)
method.
Caution is required if this method is used in conjunction with MessageAcknowledgementConfiguration.withRequiredMessageClientOutcomeOperationSupport(Outcome...)
.
See provided javadoc for more details
MessageAcknowledgementConfiguration withMessageClientAcknowledgement()
Client message acknowledgement is default behaviour, and this method's purpose is to switch back to client acknowledgement after auto-ack was turned on.
MessageAcknowledgementConfiguration withRequiredMessageClientOutcomeOperationSupport(MessageAcknowledgementConfiguration.Outcome... requiredOutcomes)
The default value is: Outcome.ACCEPTED
.
Enable of negative message settlement options is required to prepare the receiver to work
with any of negative message settlement options such as Outcome.FAILED
or Outcome.REJECTED
Usage this configuration option in conjunction with Outcome.FAILED and Outcome.REJECTED
is mutually exclusive with MessageAcknowledgementConfiguration.withMessageAutoAcknowledgement()
requiredOutcomes
- if set, receiver will respect requirements provided. Start of the
receiver with older unsupported broker will be prevented.Copyright 2019-2024 Solace Corporation. All rights reserved.