## Contents

- Properties

class solace.MessageConsumerProperties

Defines the properties for a solace.MessageConsumer.

## Constructor Top

| MessageConsumerProperties ( ) |  |

## Properties Top

solace.MessageConsumerAcknowledgeMode | acknowledgeMode = `solace.MessageConsumerAcknowledgeMode.AUTO` |  |
Number | acknowledgeThreshold = `60` |  |
Number | acknowledgeTimeoutInMsecs = `1000` |  |
Boolean | activeIndicationEnabled = `false` |  |
Number | connectAttempts = `3` |  |
Number | connectTimeoutInMsecs = `10000` |  |
Boolean | noLocal = `false` |  |
solace.QueueDescriptor | queueDescriptor |  |
solace.QueueProperties | queueProperties |  |
solace.ReplayStartLocation | replayStartLocation = `undefined.` |  |
solace.Destination | topicEndpointSubscription = `undefined` |  |
Number | transportAcknowledgeThresholdPercentage = `60` |  |
Number | transportAcknowledgeTimeoutInMsecs = `1000` |  |
Number | windowSize = `255` |  |

## Constructor details Top

###
MessageConsumerProperties ( )

Defines the properties for a solace.MessageConsumer.

## Properties Detail Top

###
public solace.MessageConsumerAcknowledgeMode acknowledgeMode = `solace.MessageConsumerAcknowledgeMode.AUTO`

The Application Acknowledgement mode for the Message Consumer.

When the acknowledgement mode is solace.MessageConsumerAcknowledgeMode.CLIENT, a message is Application Acknowledged when the application calls solace.Message#acknowledge on that message.

When the acknowledge mode is solace.MessageConsumerAcknowledgeMode.AUTO, a message is Application Acknowledged by the API after all solace.MessageConsumerEventName#event:MESSAGE listeners are called and none throw an exception. If a message handler throws, the message can still be acknowledged by calling solace.Message#acknowledge, but this would not be a recommended practice.

When received messages are Application Acknowledged they are removed from the Guaranteed Message storage on the Solace Message Router. Message Consumer Application Acknowledged, only remove messages from the Solace Message Router.

In particular, withholding Message Consumer Acknowledgemnts does not stop message delivery. For Message Consumer flow control (aka transport acknowledgemeent) see solace.MessageConsumer.stop/solace.MessageConsumer.start. Message Consumer flow control may also be imlpemented by removing the solace.MessageConsumerEventName#event:MESSAGE listener.

Flow control and transport acknowledgements characteristics are defined by solace.MessageConsumerProperties.transportAcknowledgeThresholdPercentage and solace.MessageConsumerProperties.transportAcknowledgeTimeoutInMsecs

###
public Number acknowledgeThreshold = `60`

The threshold for sending an acknowledgement, as a percentage. The API sends a transport acknowledgment every N messages where N is calculated as this percentage of the transport window size if the endpoint's max-delivered-unacked-msgs-per-flow setting at bind time is greater than or equal to the transport window size. Otherwise, N is calculated as this percentage of the endpoint's max-delivered-unacked-msgs-per-flow setting at bind time.

- The valid range is 1 <= transportAcknowledgeThresholdPercentage <= 75.

Deprecated: Yes

###
public Number acknowledgeTimeoutInMsecs = `1000`

The transport acknowledgement timeout for guaranteed messaging. When the solace.MessageConsumerProperties.transportAcknowledgeTimeoutInMsecs is not exceeded, acknowledgements will be returned to the router at intervals not less than this value.

- The valid range is 20 <= transportAcknowledgeTimeoutInMsecs <= 1500.

Deprecated: Yes

###
public Boolean activeIndicationEnabled = `false`

When enabled, a Guaranteed Messaging Consumer requests Active and Inactive events from the router and emits them to interested listeners.

See {solace.MessageConsumerEvent.ACTIVE}

See {solace.MessageConsumerEvent.INACTIVE}

###
public Number connectAttempts = `3`

Gets and sets the maximum number of bind attempts when creating a connection to the Solace Message Router.

- The valid range is >= 1.

###
public Number connectTimeoutInMsecs = `10000`

The bind timeout in milliseconds when creating a connection to the Solace Message Router.

- The valid range is >= 50.

###
public Boolean noLocal = `false`

When enabled, a Guaranteed Messaging Consumer does not receive messages published in the same Session, even if the endpoint contains a subscription that matches the published message.

###
public solace.QueueDescriptor queueDescriptor

Defines the queue from which to consume.

- For durable queues and durable topic endpoints, this must be a solace.QueueDescriptor.
- When an solace.AbstractQueueDescriptor is used, the name is generated when the solace.MessageConsumer is connected. The generated descriptor can be queried from the consumer after it has successfully connected by calling solace.MessageConsumer#getQueueDescriptor.

###
public solace.QueueProperties queueProperties

Gets the properties of the remote queue.

- For temporary queues and temporary topic endpoints, these properties define the queue that is created.
- For durable queues, these must be unset on consumer creation. The values will be populated after the queue is connected and can be retrieved by calling solace.MessageConsumer.#getQueueProperties.

###
public solace.ReplayStartLocation replayStartLocation = `undefined.`

When a Flow is created, the application may request replay of messages from the replay log, even messages that have been previously delivered and removed the from topic endpoint or queue. The default is undefined, and indicates that no replay is requested.

When defined the replay start location must be a {solace.ReplayStartLocation} object as returned by {SolClientFactory.createReplayStartLocationBeginning()} or {SolClientFactory.createReplayStartLocationDate()}.

The {solace.ReplayStartLocation} returned by {SolClientFactory.createReplayStartLocationBeginning()} indicate that all messages available should be replayed.

The replay start location returned by {SolClientFactory.createReplayStartLocationDate()} indicates that all messages logged since a given date must be retrieved.

###
public solace.Destination topicEndpointSubscription = `undefined`

This must be undefined if solace.MessageConsumerProperties#queueDescriptor#type is not {solace.QueueType.TOPIC_ENDPOINT}.

If solace.MessageConsumerProperties#queueDescriptor#durable is false, this may be left undefined to generate the topic endpoint's destination. When generated, the destination can be obtained from the {solace.MessageConsumer} after it is connected by calling solace.MessageConsumer#getDestination.

###
public Number transportAcknowledgeThresholdPercentage = `60`

The threshold for sending an acknowledgement, as a percentage. The API sends a transport acknowledgment every N messages where N is calculated as this percentage of the transport window size if the endpoint's max-delivered-unacked-msgs-per-flow setting at bind time is greater than or equal to the transport window size. Otherwise, N is calculated as this percentage of the endpoint's max-delivered-unacked-msgs-per-flow setting at bind time.

- The valid range is 1 <= transportAcknowledgeThresholdPercentage <= 75.

Deprecated: Yes

###
public Number transportAcknowledgeTimeoutInMsecs = `1000`

The transport acknowledgement timeout for guaranteed messaging. When the solace.MessageConsumerProperties.transportAcknowledgeTimeoutInMsecs is not exceeded, acknowledgements will be returned to the router at intervals not less than this value.

- The valid range is 20 <= transportAcknowledgeTimeoutInMsecs <= 1500.

###
public Number windowSize = `255`

The window size for Guaranteed Message delivery. This is the maximum number of messages that will be prefetched from the Solace Messaging Router and queued internally by the API while waiting for the application to accept delivery of the messages.

- The valid range is 1 <= windowSize <= 255.