30
30
//---------------------------------------------------------------------------
31
31
32
32
using System . Threading . RateLimiting ;
33
- using RabbitMQ . Client . Impl ;
34
33
35
34
namespace RabbitMQ . Client
36
35
{
@@ -41,11 +40,24 @@ public sealed class CreateChannelOptions
41
40
{
42
41
/// <summary>
43
42
/// Enable or disable publisher confirmations on this channel. Defaults to <c>false</c>
43
+ ///
44
+ /// Note that, if this is enabled, and <see cref="PublisherConfirmationTrackingEnabled"/> is <b>not</b>
45
+ /// enabled, the broker may send a <c>basic.return</c> response if a message is published with <c>mandatory: true</c>
46
+ /// and the broker can't route the message. This response will not, however, contain the publish sequence number
47
+ /// for the message, so it is difficult to correlate the response to the correct message. Users of this library
48
+ /// could add the <see cref="Constants.PublishSequenceNumberHeader"/> header with the value returned by
49
+ /// <see cref="IChannel.GetNextPublishSequenceNumberAsync(System.Threading.CancellationToken)"/> to allow correlation
50
+ /// of the response with the correct message.
44
51
/// </summary>
45
52
public bool PublisherConfirmationsEnabled { get ; set ; } = false ;
46
53
47
54
/// <summary>
48
55
/// Should this library track publisher confirmations for you? Defaults to <c>false</c>
56
+ ///
57
+ /// When enabled, the <see cref="Constants.PublishSequenceNumberHeader" /> header will be
58
+ /// added to every published message, and will contain the message's publish sequence number.
59
+ /// If the broker then sends a <c>basic.return</c> response for the message, this library can
60
+ /// then correctly handle the message.
49
61
/// </summary>
50
62
public bool PublisherConfirmationTrackingEnabled { get ; set ; } = false ;
51
63
0 commit comments