Table of Contents

Class RabbitTemplate

Namespace
Steeltoe.Messaging.RabbitMQ.Core
Assembly
Steeltoe.Messaging.RabbitMQ.dll
public class RabbitTemplate : AbstractMessagingTemplate<RabbitDestination>, IMessageSendingOperations<RabbitDestination>, IMessageReceivingOperations<RabbitDestination>, IMessageRequestReplyOperations<RabbitDestination>, IRabbitTemplate, IServiceNameAware, IMessageListener, IListenerContainerAware, IPublisherCallbackChannel.IListener, IDisposable
Inheritance
RabbitTemplate
Implements
Derived
Inherited Members

Constructors

RabbitTemplate(ILogger)

public RabbitTemplate(ILogger logger = null)

Parameters

logger ILogger

RabbitTemplate(IOptionsMonitor<RabbitOptions>, IConnectionFactory, ILogger)

public RabbitTemplate(IOptionsMonitor<RabbitOptions> optionsMonitor, IConnectionFactory connectionFactory, ILogger logger = null)

Parameters

optionsMonitor IOptionsMonitor<RabbitOptions>
connectionFactory IConnectionFactory
logger ILogger

RabbitTemplate(IOptionsMonitor<RabbitOptions>, IConnectionFactory, ISmartMessageConverter, ILogger)

[ActivatorUtilitiesConstructor]
public RabbitTemplate(IOptionsMonitor<RabbitOptions> optionsMonitor, IConnectionFactory connectionFactory, ISmartMessageConverter messageConverter, ILogger logger = null)

Parameters

optionsMonitor IOptionsMonitor<RabbitOptions>
connectionFactory IConnectionFactory
messageConverter ISmartMessageConverter
logger ILogger

RabbitTemplate(RabbitOptions, IConnectionFactory, ILogger)

public RabbitTemplate(RabbitOptions options, IConnectionFactory connectionFactory, ILogger logger = null)

Parameters

options RabbitOptions
connectionFactory IConnectionFactory
logger ILogger

RabbitTemplate(RabbitOptions, IConnectionFactory, ISmartMessageConverter, ILogger)

public RabbitTemplate(RabbitOptions options, IConnectionFactory connectionFactory, ISmartMessageConverter messageConverter, ILogger logger = null)

Parameters

options RabbitOptions
connectionFactory IConnectionFactory
messageConverter ISmartMessageConverter
logger ILogger

RabbitTemplate(IConnectionFactory, ILogger)

public RabbitTemplate(IConnectionFactory connectionFactory, ILogger logger = null)

Parameters

connectionFactory IConnectionFactory
logger ILogger

Fields

DEFAULT_SERVICE_NAME

public const string DEFAULT_SERVICE_NAME = "rabbitTemplate"

Field Value

string

_logger

protected readonly ILogger _logger

Field Value

ILogger

Properties

AfterReceivePostProcessors

public virtual IList<IMessagePostProcessor> AfterReceivePostProcessors { get; }

Property Value

IList<IMessagePostProcessor>

BeforePublishPostProcessors

public virtual IList<IMessagePostProcessor> BeforePublishPostProcessors { get; }

Property Value

IList<IMessagePostProcessor>

ConfirmCallback

public virtual RabbitTemplate.IConfirmCallback ConfirmCallback { get; set; }

Property Value

RabbitTemplate.IConfirmCallback

ConnectionFactory

public virtual IConnectionFactory ConnectionFactory { get; set; }

Property Value

IConnectionFactory

ContainerAckMode

public virtual AcknowledgeMode ContainerAckMode { get; set; }

Property Value

AcknowledgeMode

CorrelationDataPostProcessor

public virtual ICorrelationDataPostProcessor CorrelationDataPostProcessor { get; set; }

Property Value

ICorrelationDataPostProcessor

CorrelationKey

public virtual string CorrelationKey { get; set; }

Property Value

string

DefaultReceiveQueue

public virtual string DefaultReceiveQueue { get; set; }

Property Value

string

Encoding

public virtual Encoding Encoding { get; set; }

Property Value

Encoding

EvaluationContext

public virtual IEvaluationContext EvaluationContext { get; set; }

Property Value

IEvaluationContext

Exchange

public virtual string Exchange { get; set; }

Property Value

string

IsChannelTransacted

public virtual bool IsChannelTransacted { get; set; }

Property Value

bool

IsConfirmListener

Gets a value indicating whether this is a confirm listener

public virtual bool IsConfirmListener { get; }

Property Value

bool

IsReturnListener

Gets a value indicating whether this is a returns listener

public virtual bool IsReturnListener { get; }

Property Value

bool

IsRunning

public virtual bool IsRunning { get; }

Property Value

bool

Mandatory

public virtual bool Mandatory { get; set; }

Property Value

bool

MandatoryExpression

public virtual IExpression MandatoryExpression { get; set; }

Property Value

IExpression

MandatoryExpressionString

public virtual string MandatoryExpressionString { get; set; }

Property Value

string

MessagePropertiesConverter

public virtual IMessageHeadersConverter MessagePropertiesConverter { get; set; }

Property Value

IMessageHeadersConverter

NoLocalReplyConsumer

public virtual bool NoLocalReplyConsumer { get; set; }

Property Value

bool

Options

protected RabbitOptions Options { get; }

Property Value

RabbitOptions

ReceiveConnectionFactorySelectorExpression

public virtual IExpression ReceiveConnectionFactorySelectorExpression { get; set; }

Property Value

IExpression

ReceiveTimeout

public virtual int ReceiveTimeout { get; set; }

Property Value

int

RecoveryCallback

public virtual IRecoveryCallback RecoveryCallback { get; set; }

Property Value

IRecoveryCallback

ReplyAddress

public virtual string ReplyAddress { get; set; }

Property Value

string

ReplyErrorHandler

public virtual IErrorHandler ReplyErrorHandler { get; set; }

Property Value

IErrorHandler

ReplyTimeout

public virtual int ReplyTimeout { get; set; }

Property Value

int

RetryTemplate

public virtual IRetryOperation RetryTemplate { get; set; }

Property Value

IRetryOperation

ReturnCallback

public virtual RabbitTemplate.IReturnCallback ReturnCallback { get; set; }

Property Value

RabbitTemplate.IReturnCallback

RoutingKey

public virtual string RoutingKey { get; set; }

Property Value

string

SendConnectionFactorySelectorExpression

public virtual IExpression SendConnectionFactorySelectorExpression { get; set; }

Property Value

IExpression

ServiceName

public virtual string ServiceName { get; set; }

Property Value

string

UUID

Gets the UUID used to identify this listener for returns

public virtual string UUID { get; }

Property Value

string

UseDirectReplyToContainer

public virtual bool UseDirectReplyToContainer { get; set; }

Property Value

bool

UsePublisherConnection

public virtual bool UsePublisherConnection { get; set; }

Property Value

bool

UseTemporaryReplyQueues

public virtual bool UseTemporaryReplyQueues { get; set; }

Property Value

bool

UserCorrelationId

public virtual bool UserCorrelationId { get; set; }

Property Value

bool

UserIdExpression

public virtual IExpression UserIdExpression { get; set; }

Property Value

IExpression

UserIdExpressionString

public virtual string UserIdExpressionString { get; set; }

Property Value

string

Methods

AddAfterReceivePostProcessors(params IMessagePostProcessor[])

public virtual void AddAfterReceivePostProcessors(params IMessagePostProcessor[] afterReceivePostProcessors)

Parameters

afterReceivePostProcessors IMessagePostProcessor[]

AddBeforePublishPostProcessors(params IMessagePostProcessor[])

public virtual void AddBeforePublishPostProcessors(params IMessagePostProcessor[] beforePublishPostProcessors)

Parameters

beforePublishPostProcessors IMessagePostProcessor[]

AddListener(IModel)

public virtual void AddListener(IModel channel)

Parameters

channel IModel

ConvertAndSend(object, IMessagePostProcessor)

public virtual void ConvertAndSend(object message, IMessagePostProcessor messagePostProcessor)

Parameters

message object
messagePostProcessor IMessagePostProcessor

ConvertAndSend(object, IMessagePostProcessor, CorrelationData)

public virtual void ConvertAndSend(object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData)

Parameters

message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData

ConvertAndSend(string, object)

public virtual void ConvertAndSend(string routingKey, object message)

Parameters

routingKey string
message object

ConvertAndSend(string, object, CorrelationData)

public virtual void ConvertAndSend(string routingKey, object message, CorrelationData correlationData)

Parameters

routingKey string
message object
correlationData CorrelationData

ConvertAndSend(string, object, IMessagePostProcessor)

public virtual void ConvertAndSend(string routingKey, object message, IMessagePostProcessor messagePostProcessor)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor

ConvertAndSend(string, object, IMessagePostProcessor, CorrelationData)

public virtual void ConvertAndSend(string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData

ConvertAndSend(string, string, object)

public virtual void ConvertAndSend(string exchange, string routingKey, object message)

Parameters

exchange string
routingKey string
message object

ConvertAndSend(string, string, object, CorrelationData)

public virtual void ConvertAndSend(string exchange, string routingKey, object message, CorrelationData correlationData)

Parameters

exchange string
routingKey string
message object
correlationData CorrelationData

ConvertAndSend(string, string, object, IMessagePostProcessor)

public virtual void ConvertAndSend(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor

ConvertAndSend(string, string, object, IMessagePostProcessor, CorrelationData)

public virtual void ConvertAndSend(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData

ConvertAndSendAsync(object, IMessagePostProcessor, CorrelationData, CancellationToken)

public virtual Task ConvertAndSendAsync(object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task

ConvertAndSendAsync(object, IMessagePostProcessor, CancellationToken)

public virtual Task ConvertAndSendAsync(object message, IMessagePostProcessor messagePostProcessor, CancellationToken cancellationToken = default)

Parameters

message object
messagePostProcessor IMessagePostProcessor
cancellationToken CancellationToken

Returns

Task

ConvertAndSendAsync(string, object, CorrelationData, CancellationToken)

public virtual Task ConvertAndSendAsync(string routingKey, object message, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task

ConvertAndSendAsync(string, object, IMessagePostProcessor, CorrelationData, CancellationToken)

public virtual Task ConvertAndSendAsync(string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task

ConvertAndSendAsync(string, object, IMessagePostProcessor, CancellationToken)

public virtual Task ConvertAndSendAsync(string routingKey, object message, IMessagePostProcessor messagePostProcessor, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor
cancellationToken CancellationToken

Returns

Task

ConvertAndSendAsync(string, object, CancellationToken)

public virtual Task ConvertAndSendAsync(string routingKey, object message, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
cancellationToken CancellationToken

Returns

Task

ConvertAndSendAsync(string, string, object, CorrelationData, CancellationToken)

public virtual Task ConvertAndSendAsync(string exchange, string routingKey, object message, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task

ConvertAndSendAsync(string, string, object, IMessagePostProcessor, CorrelationData, CancellationToken)

public virtual Task ConvertAndSendAsync(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task

ConvertAndSendAsync(string, string, object, IMessagePostProcessor, CancellationToken)

public virtual Task ConvertAndSendAsync(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
cancellationToken CancellationToken

Returns

Task

ConvertAndSendAsync(string, string, object, CancellationToken)

public virtual Task ConvertAndSendAsync(string exchange, string routingKey, object message, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
cancellationToken CancellationToken

Returns

Task

ConvertMessageIfNecessary(object)

protected virtual IMessage ConvertMessageIfNecessary(object message)

Parameters

message object

Returns

IMessage

ConvertRabbitAccessException(Exception)

protected virtual Exception ConvertRabbitAccessException(Exception ex)

Parameters

ex Exception

Returns

Exception

ConvertSendAndReceiveAsType(object, CorrelationData, Type)

public virtual object ConvertSendAndReceiveAsType(object message, CorrelationData correlationData, Type type)

Parameters

message object
correlationData CorrelationData
type Type

Returns

object

ConvertSendAndReceiveAsType(object, IMessagePostProcessor, CorrelationData, Type)

public virtual object ConvertSendAndReceiveAsType(object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, Type type)

Parameters

message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
type Type

Returns

object

ConvertSendAndReceiveAsType(object, IMessagePostProcessor, Type)

public virtual object ConvertSendAndReceiveAsType(object message, IMessagePostProcessor messagePostProcessor, Type type)

Parameters

message object
messagePostProcessor IMessagePostProcessor
type Type

Returns

object

ConvertSendAndReceiveAsType(object, Type)

public virtual object ConvertSendAndReceiveAsType(object message, Type type)

Parameters

message object
type Type

Returns

object

ConvertSendAndReceiveAsType(string, object, CorrelationData, Type)

public virtual object ConvertSendAndReceiveAsType(string routingKey, object message, CorrelationData correlationData, Type type)

Parameters

routingKey string
message object
correlationData CorrelationData
type Type

Returns

object

ConvertSendAndReceiveAsType(string, object, IMessagePostProcessor, CorrelationData, Type)

public virtual object ConvertSendAndReceiveAsType(string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, Type type)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
type Type

Returns

object

ConvertSendAndReceiveAsType(string, object, IMessagePostProcessor, Type)

public virtual object ConvertSendAndReceiveAsType(string routingKey, object message, IMessagePostProcessor messagePostProcessor, Type type)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor
type Type

Returns

object

ConvertSendAndReceiveAsType(string, object, Type)

public virtual object ConvertSendAndReceiveAsType(string routingKey, object message, Type type)

Parameters

routingKey string
message object
type Type

Returns

object

ConvertSendAndReceiveAsType(string, string, object, CorrelationData, Type)

public virtual object ConvertSendAndReceiveAsType(string exchange, string routingKey, object message, CorrelationData correlationData, Type type)

Parameters

exchange string
routingKey string
message object
correlationData CorrelationData
type Type

Returns

object

ConvertSendAndReceiveAsType(string, string, object, IMessagePostProcessor, CorrelationData, Type)

public virtual object ConvertSendAndReceiveAsType(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, Type type)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
type Type

Returns

object

ConvertSendAndReceiveAsType(string, string, object, IMessagePostProcessor, Type)

public virtual object ConvertSendAndReceiveAsType(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, Type type)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
type Type

Returns

object

ConvertSendAndReceiveAsType(string, string, object, Type)

public virtual object ConvertSendAndReceiveAsType(string exchange, string routingKey, object message, Type type)

Parameters

exchange string
routingKey string
message object
type Type

Returns

object

ConvertSendAndReceiveAsTypeAsync(object, CorrelationData, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(object message, CorrelationData correlationData, Type type, CancellationToken cancellationToken = default)

Parameters

message object
correlationData CorrelationData
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(object, IMessagePostProcessor, CorrelationData, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, Type type, CancellationToken cancellationToken = default)

Parameters

message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(object, IMessagePostProcessor, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(object message, IMessagePostProcessor messagePostProcessor, Type type, CancellationToken cancellationToken = default)

Parameters

message object
messagePostProcessor IMessagePostProcessor
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(object, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(object message, Type type, CancellationToken cancellationToken = default)

Parameters

message object
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(string, object, CorrelationData, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(string routingKey, object message, CorrelationData correlationData, Type type, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
correlationData CorrelationData
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(string, object, IMessagePostProcessor, CorrelationData, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, Type type, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(string, object, IMessagePostProcessor, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(string routingKey, object message, IMessagePostProcessor messagePostProcessor, Type type, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(string, object, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(string routingKey, object message, Type type, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(string, string, object, CorrelationData, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(string exchange, string routingKey, object message, CorrelationData correlationData, Type type, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
correlationData CorrelationData
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(string, string, object, IMessagePostProcessor, CorrelationData, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, Type type, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(string, string, object, IMessagePostProcessor, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, Type type, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsTypeAsync(string, string, object, Type, CancellationToken)

public virtual Task<object> ConvertSendAndReceiveAsTypeAsync(string exchange, string routingKey, object message, Type type, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
type Type
cancellationToken CancellationToken

Returns

Task<object>

ConvertSendAndReceiveAsync<T>(object, CorrelationData, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(object message, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

message object
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveAsync<T>(object, IMessagePostProcessor, CorrelationData, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveAsync<T>(object, IMessagePostProcessor, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(object message, IMessagePostProcessor messagePostProcessor, CancellationToken cancellationToken = default)

Parameters

message object
messagePostProcessor IMessagePostProcessor
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveAsync<T>(string, object, CorrelationData, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(string routingKey, object message, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveAsync<T>(string, object, IMessagePostProcessor, CorrelationData, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveAsync<T>(string, object, IMessagePostProcessor, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(string routingKey, object message, IMessagePostProcessor messagePostProcessor, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveAsync<T>(string, object, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(string routingKey, object message, CancellationToken cancellationToken = default)

Parameters

routingKey string
message object
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveAsync<T>(string, string, object, CorrelationData, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(string exchange, string routingKey, object message, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveAsync<T>(string, string, object, IMessagePostProcessor, CorrelationData, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveAsync<T>(string, string, object, IMessagePostProcessor, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveAsync<T>(string, string, object, CancellationToken)

public virtual Task<T> ConvertSendAndReceiveAsync<T>(string exchange, string routingKey, object message, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message object
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ConvertSendAndReceiveRaw(string, string, object, IMessagePostProcessor, CorrelationData)

protected IMessage ConvertSendAndReceiveRaw(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData

Returns

IMessage

ConvertSendAndReceive<T>(object, CorrelationData)

public virtual T ConvertSendAndReceive<T>(object message, CorrelationData correlationData)

Parameters

message object
correlationData CorrelationData

Returns

T

Type Parameters

T

ConvertSendAndReceive<T>(object, IMessagePostProcessor)

public virtual T ConvertSendAndReceive<T>(object message, IMessagePostProcessor messagePostProcessor)

Parameters

message object
messagePostProcessor IMessagePostProcessor

Returns

T

Type Parameters

T

ConvertSendAndReceive<T>(object, IMessagePostProcessor, CorrelationData)

public virtual T ConvertSendAndReceive<T>(object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData)

Parameters

message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData

Returns

T

Type Parameters

T

ConvertSendAndReceive<T>(string, object)

public virtual T ConvertSendAndReceive<T>(string routingKey, object message)

Parameters

routingKey string
message object

Returns

T

Type Parameters

T

ConvertSendAndReceive<T>(string, object, CorrelationData)

public virtual T ConvertSendAndReceive<T>(string routingKey, object message, CorrelationData correlationData)

Parameters

routingKey string
message object
correlationData CorrelationData

Returns

T

Type Parameters

T

ConvertSendAndReceive<T>(string, object, IMessagePostProcessor)

public virtual T ConvertSendAndReceive<T>(string routingKey, object message, IMessagePostProcessor messagePostProcessor)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor

Returns

T

Type Parameters

T

ConvertSendAndReceive<T>(string, object, IMessagePostProcessor, CorrelationData)

public virtual T ConvertSendAndReceive<T>(string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData)

Parameters

routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData

Returns

T

Type Parameters

T

ConvertSendAndReceive<T>(string, string, object)

public virtual T ConvertSendAndReceive<T>(string exchange, string routingKey, object message)

Parameters

exchange string
routingKey string
message object

Returns

T

Type Parameters

T

ConvertSendAndReceive<T>(string, string, object, CorrelationData)

public virtual T ConvertSendAndReceive<T>(string exchange, string routingKey, object message, CorrelationData correlationData)

Parameters

exchange string
routingKey string
message object
correlationData CorrelationData

Returns

T

Type Parameters

T

ConvertSendAndReceive<T>(string, string, object, IMessagePostProcessor)

public virtual T ConvertSendAndReceive<T>(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor

Returns

T

Type Parameters

T

ConvertSendAndReceive<T>(string, string, object, IMessagePostProcessor, CorrelationData)

public virtual T ConvertSendAndReceive<T>(string exchange, string routingKey, object message, IMessagePostProcessor messagePostProcessor, CorrelationData correlationData)

Parameters

exchange string
routingKey string
message object
messagePostProcessor IMessagePostProcessor
correlationData CorrelationData

Returns

T

Type Parameters

T

CorrelationConvertAndSend(object, CorrelationData)

public virtual void CorrelationConvertAndSend(object message, CorrelationData correlationData)

Parameters

message object
correlationData CorrelationData

CreateConnection()

protected virtual IConnection CreateConnection()

Returns

IConnection

DetermineConfirmsReturnsCapability(IConnectionFactory)

public virtual void DetermineConfirmsReturnsCapability(IConnectionFactory connectionFactory)

Parameters

connectionFactory IConnectionFactory

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public virtual void Dispose()

DoReceive(RabbitDestination)

protected override IMessage DoReceive(RabbitDestination destination)

Parameters

destination RabbitDestination

Returns

IMessage

DoReceive(string, int, CancellationToken)

protected virtual IMessage DoReceive(string queueName, int timeoutMillis, CancellationToken cancellationToken)

Parameters

queueName string
timeoutMillis int
cancellationToken CancellationToken

Returns

IMessage

DoReceiveAndConvert(string, int, Type, CancellationToken)

protected virtual object DoReceiveAndConvert(string queueName, int timeoutMillis, Type type, CancellationToken cancellationToken = default)

Parameters

queueName string
timeoutMillis int
type Type
cancellationToken CancellationToken

Returns

object

DoReceiveAsync(RabbitDestination, CancellationToken)

protected override Task<IMessage> DoReceiveAsync(RabbitDestination destination, CancellationToken cancellationToken)

Parameters

destination RabbitDestination
cancellationToken CancellationToken

Returns

Task<IMessage>

DoReceiveNoWait(string, CancellationToken)

protected virtual IMessage DoReceiveNoWait(string queueName, CancellationToken cancellationToken = default)

Parameters

queueName string
cancellationToken CancellationToken

Returns

IMessage

DoSend(IModel, string, string, IMessage, bool, CorrelationData, CancellationToken)

protected virtual void DoSend(IModel channel, string exchangeArg, string routingKeyArg, IMessage message, bool mandatory, CorrelationData correlationData, CancellationToken cancellationToken)

Parameters

channel IModel
exchangeArg string
routingKeyArg string
message IMessage
mandatory bool
correlationData CorrelationData
cancellationToken CancellationToken

DoSend(RabbitDestination, IMessage)

protected override void DoSend(RabbitDestination destination, IMessage message)

Parameters

destination RabbitDestination
message IMessage

DoSendAndReceive(RabbitDestination, IMessage)

protected override IMessage DoSendAndReceive(RabbitDestination destination, IMessage requestMessage)

Parameters

destination RabbitDestination
requestMessage IMessage

Returns

IMessage

DoSendAndReceive(string, string, IMessage, CorrelationData, CancellationToken)

protected virtual IMessage DoSendAndReceive(string exchange, string routingKey, IMessage message, CorrelationData correlationData, CancellationToken cancellationToken)

Parameters

exchange string
routingKey string
message IMessage
correlationData CorrelationData
cancellationToken CancellationToken

Returns

IMessage

DoSendAndReceiveAsync(RabbitDestination, IMessage, CancellationToken)

protected override Task<IMessage> DoSendAndReceiveAsync(RabbitDestination destination, IMessage requestMessage, CancellationToken cancellationToken = default)

Parameters

destination RabbitDestination
requestMessage IMessage
cancellationToken CancellationToken

Returns

Task<IMessage>

DoSendAndReceiveWithDirect(string, string, IMessage, CorrelationData, CancellationToken)

protected virtual IMessage DoSendAndReceiveWithDirect(string exchange, string routingKey, IMessage message, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message IMessage
correlationData CorrelationData
cancellationToken CancellationToken

Returns

IMessage

DoSendAndReceiveWithFixed(string, string, IMessage, CorrelationData, CancellationToken)

protected virtual IMessage DoSendAndReceiveWithFixed(string exchange, string routingKey, IMessage message, CorrelationData correlationData, CancellationToken cancellationToken)

Parameters

exchange string
routingKey string
message IMessage
correlationData CorrelationData
cancellationToken CancellationToken

Returns

IMessage

DoSendAndReceiveWithTemporary(string, string, IMessage, CorrelationData, CancellationToken)

protected virtual IMessage DoSendAndReceiveWithTemporary(string exchange, string routingKey, IMessage message, CorrelationData correlationData, CancellationToken cancellationToken)

Parameters

exchange string
routingKey string
message IMessage
correlationData CorrelationData
cancellationToken CancellationToken

Returns

IMessage

DoSendAsync(RabbitDestination, IMessage, CancellationToken)

protected override Task DoSendAsync(RabbitDestination destination, IMessage message, CancellationToken cancellationToken)

Parameters

destination RabbitDestination
message IMessage
cancellationToken CancellationToken

Returns

Task

DoStart()

protected virtual Task DoStart()

Returns

Task

DoStop()

protected virtual Task DoStop()

Returns

Task

Execute(Action<IModel>)

public virtual void Execute(Action<IModel> action)

Parameters

action Action<IModel>

Execute<T>(Func<IModel, T>)

public virtual T Execute<T>(Func<IModel, T> action)

Parameters

action Func<IModel, T>

Returns

T

Type Parameters

T

GetDefaultExchange()

protected virtual string GetDefaultExchange()

Returns

string

GetDefaultRoutingKey()

protected virtual string GetDefaultRoutingKey()

Returns

string

GetExpectedQueueNames()

public virtual List<string> GetExpectedQueueNames()

Returns

List<string>

GetTransactionalResourceHolder()

protected virtual RabbitResourceHolder GetTransactionalResourceHolder()

Returns

RabbitResourceHolder

GetUnconfirmed(long)

public virtual ICollection<CorrelationData> GetUnconfirmed(long age)

Parameters

age long

Returns

ICollection<CorrelationData>

GetUnconfirmedCount()

public virtual int GetUnconfirmedCount()

Returns

int

HandleConfirm(PendingConfirm, bool)

Invoked by the channel when a confirmation is received

public virtual void HandleConfirm(PendingConfirm pendingConfirm, bool ack)

Parameters

pendingConfirm PendingConfirm

the pending confirmation

ack bool

true when an ack; false when a nack

HandleReturn(int, string, string, string, IBasicProperties, byte[])

Invoked when a basic return command is received

public virtual void HandleReturn(int replyCode, string replyText, string exchange, string routingKey, IBasicProperties properties, byte[] body)

Parameters

replyCode int

the reason code of the return

replyText string

the text from the broker describing the return

exchange string

the exchange the returned message was originally published to.

routingKey string

the routing key used when the message was originally published.

properties IBasicProperties

the content header of the message.

body byte[]

the body of the message

Invoke<T>(Func<IRabbitTemplate, T>)

public virtual T Invoke<T>(Func<IRabbitTemplate, T> rabbitOperations)

Parameters

rabbitOperations Func<IRabbitTemplate, T>

Returns

T

Type Parameters

T

Invoke<T>(Func<IRabbitTemplate, T>, Action<object, BasicAckEventArgs>, Action<object, BasicNackEventArgs>)

public virtual T Invoke<T>(Func<IRabbitTemplate, T> rabbitOperations, Action<object, BasicAckEventArgs> acks, Action<object, BasicNackEventArgs> nacks)

Parameters

rabbitOperations Func<IRabbitTemplate, T>
acks Action<object, BasicAckEventArgs>
nacks Action<object, BasicNackEventArgs>

Returns

T

Type Parameters

T

IsChannelLocallyTransacted(IModel)

protected virtual bool IsChannelLocallyTransacted(IModel channel)

Parameters

channel IModel

Returns

bool

IsMandatoryFor(IMessage)

public virtual bool IsMandatoryFor(IMessage message)

Parameters

message IMessage

Returns

bool

OnMessage(IMessage)

public virtual void OnMessage(IMessage message)

Parameters

message IMessage

OnMessageBatch(List<IMessage>)

public virtual void OnMessageBatch(List<IMessage> messages)

Parameters

messages List<IMessage>

Receive(int)

public virtual IMessage Receive(int timeoutMillis)

Parameters

timeoutMillis int

Returns

IMessage

Receive(string)

public virtual IMessage Receive(string queueName)

Parameters

queueName string

Returns

IMessage

Receive(string, int)

public virtual IMessage Receive(string queueName, int timeoutMillis)

Parameters

queueName string
timeoutMillis int

Returns

IMessage

ReceiveAndConvert(int, Type)

public virtual object ReceiveAndConvert(int timeoutMillis, Type type)

Parameters

timeoutMillis int
type Type

Returns

object

ReceiveAndConvert(string, int, Type)

public virtual object ReceiveAndConvert(string queueName, int timeoutMillis, Type type)

Parameters

queueName string
timeoutMillis int
type Type

Returns

object

ReceiveAndConvert(string, Type)

public virtual object ReceiveAndConvert(string queueName, Type type)

Parameters

queueName string
type Type

Returns

object

ReceiveAndConvert(Type)

public virtual object ReceiveAndConvert(Type type)

Parameters

type Type

Returns

object

ReceiveAndConvertAsync(int, Type, CancellationToken)

public virtual Task<object> ReceiveAndConvertAsync(int timeoutMillis, Type type, CancellationToken cancellationToken = default)

Parameters

timeoutMillis int
type Type
cancellationToken CancellationToken

Returns

Task<object>

ReceiveAndConvertAsync(string, int, Type, CancellationToken)

public virtual Task<object> ReceiveAndConvertAsync(string queueName, int timeoutMillis, Type type, CancellationToken cancellationToken = default)

Parameters

queueName string
timeoutMillis int
type Type
cancellationToken CancellationToken

Returns

Task<object>

ReceiveAndConvertAsync(string, Type, CancellationToken)

public virtual Task<object> ReceiveAndConvertAsync(string queueName, Type type, CancellationToken cancellationToken = default)

Parameters

queueName string
type Type
cancellationToken CancellationToken

Returns

Task<object>

ReceiveAndConvertAsync(Type, CancellationToken)

public virtual Task<object> ReceiveAndConvertAsync(Type type, CancellationToken cancellation = default)

Parameters

type Type
cancellation CancellationToken

Returns

Task<object>

ReceiveAndConvertAsync<T>(int, CancellationToken)

public virtual Task<T> ReceiveAndConvertAsync<T>(int timeoutMillis, CancellationToken cancellationToken = default)

Parameters

timeoutMillis int
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ReceiveAndConvertAsync<T>(string, int, CancellationToken)

public virtual Task<T> ReceiveAndConvertAsync<T>(string queueName, int timeoutMillis, CancellationToken cancellationToken = default)

Parameters

queueName string
timeoutMillis int
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ReceiveAndConvertAsync<T>(string, CancellationToken)

public virtual Task<T> ReceiveAndConvertAsync<T>(string queueName, CancellationToken cancellationToken = default)

Parameters

queueName string
cancellationToken CancellationToken

Returns

Task<T>

Type Parameters

T

ReceiveAndConvert<T>(int)

public virtual T ReceiveAndConvert<T>(int timeoutMillis)

Parameters

timeoutMillis int

Returns

T

Type Parameters

T

ReceiveAndConvert<T>(string)

public virtual T ReceiveAndConvert<T>(string queueName)

Parameters

queueName string

Returns

T

Type Parameters

T

ReceiveAndConvert<T>(string, int)

public virtual T ReceiveAndConvert<T>(string queueName, int timeoutMillis)

Parameters

queueName string
timeoutMillis int

Returns

T

Type Parameters

T

ReceiveAndReply<R, S>(Func<R, S>)

public virtual bool ReceiveAndReply<R, S>(Func<R, S> callback)

Parameters

callback Func<R, S>

Returns

bool

Type Parameters

R
S

ReceiveAndReply<R, S>(Func<R, S>, Func<IMessage, S, Address>)

public virtual bool ReceiveAndReply<R, S>(Func<R, S> callback, Func<IMessage, S, Address> replyToAddressCallback)

Parameters

callback Func<R, S>
replyToAddressCallback Func<IMessage, S, Address>

Returns

bool

Type Parameters

R
S

ReceiveAndReply<R, S>(Func<R, S>, string, string)

public virtual bool ReceiveAndReply<R, S>(Func<R, S> callback, string exchange, string routingKey)

Parameters

callback Func<R, S>
exchange string
routingKey string

Returns

bool

Type Parameters

R
S

ReceiveAndReply<R, S>(string, Func<R, S>)

public virtual bool ReceiveAndReply<R, S>(string queueName, Func<R, S> callback)

Parameters

queueName string
callback Func<R, S>

Returns

bool

Type Parameters

R
S

ReceiveAndReply<R, S>(string, Func<R, S>, Func<IMessage, S, Address>)

public virtual bool ReceiveAndReply<R, S>(string queueName, Func<R, S> callback, Func<IMessage, S, Address> replyToAddressCallback)

Parameters

queueName string
callback Func<R, S>
replyToAddressCallback Func<IMessage, S, Address>

Returns

bool

Type Parameters

R
S

ReceiveAndReply<R, S>(string, Func<R, S>, string, string)

public virtual bool ReceiveAndReply<R, S>(string queueName, Func<R, S> callback, string replyExchange, string replyRoutingKey)

Parameters

queueName string
callback Func<R, S>
replyExchange string
replyRoutingKey string

Returns

bool

Type Parameters

R
S

ReceiveAsync(int, CancellationToken)

public virtual Task<IMessage> ReceiveAsync(int timeoutMillis, CancellationToken cancellationToken = default)

Parameters

timeoutMillis int
cancellationToken CancellationToken

Returns

Task<IMessage>

ReceiveAsync(string, int, CancellationToken)

public virtual Task<IMessage> ReceiveAsync(string queueName, int timeoutMillis, CancellationToken cancellationToken = default)

Parameters

queueName string
timeoutMillis int
cancellationToken CancellationToken

Returns

Task<IMessage>

ReceiveAsync(string, CancellationToken)

public virtual Task<IMessage> ReceiveAsync(string queueName, CancellationToken cancellationToken = default)

Parameters

queueName string
cancellationToken CancellationToken

Returns

Task<IMessage>

RemoveAfterReceivePostProcessor(IMessagePostProcessor)

public virtual bool RemoveAfterReceivePostProcessor(IMessagePostProcessor afterReceivePostProcessor)

Parameters

afterReceivePostProcessor IMessagePostProcessor

Returns

bool

RemoveBeforePublishPostProcessor(IMessagePostProcessor)

public virtual bool RemoveBeforePublishPostProcessor(IMessagePostProcessor beforePublishPostProcessor)

Parameters

beforePublishPostProcessor IMessagePostProcessor

Returns

bool

ReplyTimedOut(string)

protected virtual void ReplyTimedOut(string correlationId)

Parameters

correlationId string

Revoke(IModel)

When called this listener should remove all references to the channel

public virtual void Revoke(IModel channel)

Parameters

channel IModel

the channel

Send(string, IMessage)

public virtual void Send(string routingKey, IMessage message)

Parameters

routingKey string
message IMessage

Send(string, string, IMessage)

public virtual void Send(string exchange, string routingKey, IMessage message)

Parameters

exchange string
routingKey string
message IMessage

Send(string, string, IMessage, CorrelationData)

public virtual void Send(string exchange, string routingKey, IMessage message, CorrelationData correlationData)

Parameters

exchange string
routingKey string
message IMessage
correlationData CorrelationData

SendAndReceive(IMessage, CorrelationData)

public virtual IMessage SendAndReceive(IMessage message, CorrelationData correlationData)

Parameters

message IMessage
correlationData CorrelationData

Returns

IMessage

SendAndReceive(string, IMessage)

public virtual IMessage SendAndReceive(string routingKey, IMessage message)

Parameters

routingKey string
message IMessage

Returns

IMessage

SendAndReceive(string, IMessage, CorrelationData)

public virtual IMessage SendAndReceive(string routingKey, IMessage message, CorrelationData correlationData)

Parameters

routingKey string
message IMessage
correlationData CorrelationData

Returns

IMessage

SendAndReceive(string, string, IMessage)

public virtual IMessage SendAndReceive(string exchange, string routingKey, IMessage message)

Parameters

exchange string
routingKey string
message IMessage

Returns

IMessage

SendAndReceive(string, string, IMessage, CorrelationData)

public virtual IMessage SendAndReceive(string exchange, string routingKey, IMessage message, CorrelationData correlationData)

Parameters

exchange string
routingKey string
message IMessage
correlationData CorrelationData

Returns

IMessage

SendAndReceiveAsync(IMessage, CorrelationData, CancellationToken)

public virtual Task<IMessage> SendAndReceiveAsync(IMessage message, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

message IMessage
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task<IMessage>

SendAndReceiveAsync(string, IMessage, CorrelationData, CancellationToken)

public virtual Task<IMessage> SendAndReceiveAsync(string routingKey, IMessage message, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

routingKey string
message IMessage
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task<IMessage>

SendAndReceiveAsync(string, IMessage, CancellationToken)

public virtual Task<IMessage> SendAndReceiveAsync(string routingKey, IMessage message, CancellationToken cancellationToken = default)

Parameters

routingKey string
message IMessage
cancellationToken CancellationToken

Returns

Task<IMessage>

SendAndReceiveAsync(string, string, IMessage, CorrelationData, CancellationToken)

public virtual Task<IMessage> SendAndReceiveAsync(string exchange, string routingKey, IMessage message, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message IMessage
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task<IMessage>

SendAndReceiveAsync(string, string, IMessage, CancellationToken)

public virtual Task<IMessage> SendAndReceiveAsync(string exchange, string routingKey, IMessage message, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message IMessage
cancellationToken CancellationToken

Returns

Task<IMessage>

SendAsync(string, IMessage, CancellationToken)

public virtual Task SendAsync(string routingKey, IMessage message, CancellationToken cancellationToken = default)

Parameters

routingKey string
message IMessage
cancellationToken CancellationToken

Returns

Task

SendAsync(string, string, IMessage, CorrelationData, CancellationToken)

public virtual Task SendAsync(string exchange, string routingKey, IMessage message, CorrelationData correlationData, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message IMessage
correlationData CorrelationData
cancellationToken CancellationToken

Returns

Task

SendAsync(string, string, IMessage, CancellationToken)

public virtual Task SendAsync(string exchange, string routingKey, IMessage message, CancellationToken cancellationToken = default)

Parameters

exchange string
routingKey string
message IMessage
cancellationToken CancellationToken

Returns

Task

SendToRabbit(IModel, string, string, bool, IMessage)

protected virtual void SendToRabbit(IModel channel, string exchange, string routingKey, bool mandatory, IMessage message)

Parameters

channel IModel
exchange string
routingKey string
mandatory bool
message IMessage

SetAfterReceivePostProcessors(params IMessagePostProcessor[])

public virtual void SetAfterReceivePostProcessors(params IMessagePostProcessor[] afterReceivePostProcessors)

Parameters

afterReceivePostProcessors IMessagePostProcessor[]

SetBeforePublishPostProcessors(params IMessagePostProcessor[])

public virtual void SetBeforePublishPostProcessors(params IMessagePostProcessor[] beforePublishPostProcessors)

Parameters

beforePublishPostProcessors IMessagePostProcessor[]

Start()

public virtual Task Start()

Returns

Task

Stop()

public virtual Task Stop()

Returns

Task

UseDirectReplyTo()

protected virtual bool UseDirectReplyTo()

Returns

bool

WaitForConfirms(int)

public virtual bool WaitForConfirms(int timeoutInMilliseconds)

Parameters

timeoutInMilliseconds int

Returns

bool

WaitForConfirmsOrDie(int)

public virtual void WaitForConfirmsOrDie(int timeoutInMilliseconds)

Parameters

timeoutInMilliseconds int