Table of Contents

Class MqttProducerEndpointConfiguration

Namespace
Silverback.Messaging.Configuration.Mqtt
Assembly
Silverback.Integration.MQTT.dll

The MQTT producer configuration.

public sealed record MqttProducerEndpointConfiguration : ProducerEndpointConfiguration<MqttProducerEndpoint>, IEquatable<EndpointConfiguration>, IEquatable<ProducerEndpointConfiguration>, IEquatable<ProducerEndpointConfiguration<MqttProducerEndpoint>>, IEquatable<MqttProducerEndpointConfiguration>
Inheritance
MqttProducerEndpointConfiguration
Implements
Inherited Members

Constructors

MqttProducerEndpointConfiguration()

public MqttProducerEndpointConfiguration()

Properties

EqualityContract

protected override Type EqualityContract { get; }

Property Value

Type

MessageExpiryInterval

Gets the message expiry interval in seconds. This interval defines the period of time that the broker stores the PUBLISH message for any matching subscribers that are not currently connected. When no message expiry interval is set, the broker must store the message for matching subscribers indefinitely. The default is null.

public uint MessageExpiryInterval { get; init; }

Property Value

uint

NoMatchingSubscribersBehavior

Gets a value indicating the behavior when no matching subscribers are found for the produced message.

public NoMatchingSubscribersBehavior NoMatchingSubscribersBehavior { get; init; }

Property Value

NoMatchingSubscribersBehavior

QualityOfServiceLevel

Gets the quality of service level (at most once, at least once or exactly once). The default is MQTTnet.Protocol.MqttQualityOfServiceLevel.AtMostOnce.

public MqttQualityOfServiceLevel QualityOfServiceLevel { get; init; }

Property Value

MqttQualityOfServiceLevel

Retain

Gets a value indicating whether the message have to be sent with the retain flag, causing them to be persisted on the broker. The default is false.

public bool Retain { get; init; }

Property Value

bool

Methods

Equals(MqttProducerEndpointConfiguration?)

public bool Equals(MqttProducerEndpointConfiguration? other)

Parameters

other MqttProducerEndpointConfiguration

Returns

bool

Equals(ProducerEndpointConfiguration<MqttProducerEndpoint>?)

public override sealed bool Equals(ProducerEndpointConfiguration<MqttProducerEndpoint>? other)

Parameters

other ProducerEndpointConfiguration<MqttProducerEndpoint>

Returns

bool

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object

Returns

bool

GetHashCode()

public override int GetHashCode()

Returns

int

PrintMembers(StringBuilder)

protected override bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

bool

ToString()

public override string ToString()

Returns

string

ValidateCore()

Validates the endpoint configuration and throws an BrokerConfigurationException if not valid.

protected override void ValidateCore()

Operators

operator ==(MqttProducerEndpointConfiguration?, MqttProducerEndpointConfiguration?)

public static bool operator ==(MqttProducerEndpointConfiguration? left, MqttProducerEndpointConfiguration? right)

Parameters

left MqttProducerEndpointConfiguration
right MqttProducerEndpointConfiguration

Returns

bool

operator !=(MqttProducerEndpointConfiguration?, MqttProducerEndpointConfiguration?)

public static bool operator !=(MqttProducerEndpointConfiguration? left, MqttProducerEndpointConfiguration? right)

Parameters

left MqttProducerEndpointConfiguration
right MqttProducerEndpointConfiguration

Returns

bool