pulsar-client-cpp
Loading...
Searching...
No Matches
Public Member Functions | List of all members
pulsar::KeySharedPolicy Class Reference

Public Member Functions

 KeySharedPolicy (const KeySharedPolicy &)
 
KeySharedPolicyoperator= (const KeySharedPolicy &)
 
KeySharedPolicy clone () const
 
KeySharedPolicysetKeySharedMode (KeySharedMode keySharedMode)
 
KeySharedMode getKeySharedMode () const
 
KeySharedPolicysetAllowOutOfOrderDelivery (bool allowOutOfOrderDelivery)
 
bool isAllowOutOfOrderDelivery () const
 
KeySharedPolicysetStickyRanges (std::initializer_list< StickyRange > ranges)
 
KeySharedPolicysetStickyRanges (const StickyRanges &ranges)
 
StickyRanges getStickyRanges () const
 

Member Function Documentation

◆ clone()

KeySharedPolicy pulsar::KeySharedPolicy::clone ( ) const

Create a new instance of KeySharedPolicy with the same initial settings as the current one.

◆ getKeySharedMode()

KeySharedMode pulsar::KeySharedPolicy::getKeySharedMode ( ) const
Returns
the KeySharedMode of KeyShared subscription

◆ getStickyRanges()

StickyRanges pulsar::KeySharedPolicy::getStickyRanges ( ) const
Returns
ranges used with sticky mode

◆ isAllowOutOfOrderDelivery()

bool pulsar::KeySharedPolicy::isAllowOutOfOrderDelivery ( ) const
Returns
true if out of order delivery is enabled

◆ setAllowOutOfOrderDelivery()

KeySharedPolicy & pulsar::KeySharedPolicy::setAllowOutOfOrderDelivery ( bool  allowOutOfOrderDelivery)

If it is enabled, it relaxes the ordering requirement and allows the broker to send out-of-order messages in case of failures. This makes it faster for new consumers to join without being stalled by an existing slow consumer.

In this case, a single consumer still receives all keys, but they may come in different orders.

Parameters
allowOutOfOrderDeliverywhether to allow for out of order delivery

◆ setKeySharedMode()

KeySharedPolicy & pulsar::KeySharedPolicy::setKeySharedMode ( KeySharedMode  keySharedMode)

Configure the KeyShared mode of KeyShared subscription

Parameters
KeySharedmode
See also
KeySharedMode

◆ setStickyRanges() [1/2]

KeySharedPolicy & pulsar::KeySharedPolicy::setStickyRanges ( const StickyRanges &  ranges)
Parameters
rangesused with sticky mode

◆ setStickyRanges() [2/2]

KeySharedPolicy & pulsar::KeySharedPolicy::setStickyRanges ( std::initializer_list< StickyRange >  ranges)
Parameters
rangesused with sticky mode
Deprecated:
use the function that takes StickyRanges instead of std::initializer_list

The documentation for this class was generated from the following file: