Class MqttMessageIdentifier
The MQTT broker doesn't provide any message identifier, so this is a client-side generated identifier (GUID).
Implements
Inherited Members
Namespace: Silverback.Messaging.Broker
Assembly: Silverback.Integration.MQTT.dll
Syntax
public sealed record MqttMessageIdentifier : IBrokerMessageIdentifier, IEquatable<IBrokerMessageIdentifier>, IEquatable<MqttMessageIdentifier>
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).
Constructors
MqttMessageIdentifier(string, string)
Initializes a new instance of the MqttMessageIdentifier class.
Declaration
public MqttMessageIdentifier(string clientId, string messageId)
Parameters
| Type | Name | Description |
|---|---|---|
| string | clientId | The client identifier. |
| string | messageId | The message identifier. |
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).
Properties
ClientId
Gets the client identifier.
Declaration
public string ClientId { get; }
Property Value
| Type | Description |
|---|---|
| string |
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).
MessageId
Gets the client-side generated message identifier.
Declaration
public string MessageId { get; }
Property Value
| Type | Description |
|---|---|
| string |
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).
Methods
Equals(IBrokerMessageIdentifier?)
The MQTT broker doesn't provide any message identifier, so this is a client-side generated identifier (GUID).
Declaration
public bool Equals(IBrokerMessageIdentifier? other)
Parameters
| Type | Name | Description |
|---|---|---|
| IBrokerMessageIdentifier | other |
Returns
| Type | Description |
|---|---|
| bool |
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).
Equals(MqttMessageIdentifier?)
The MQTT broker doesn't provide any message identifier, so this is a client-side generated identifier (GUID).
Declaration
public bool Equals(MqttMessageIdentifier? other)
Parameters
| Type | Name | Description |
|---|---|---|
| MqttMessageIdentifier | other |
Returns
| Type | Description |
|---|---|
| bool |
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).
Equals(object?)
The MQTT broker doesn't provide any message identifier, so this is a client-side generated identifier (GUID).
Declaration
public override bool Equals(object? obj)
Parameters
| Type | Name | Description |
|---|---|---|
| object | obj |
Returns
| Type | Description |
|---|---|
| bool |
Overrides
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).
GetHashCode()
The MQTT broker doesn't provide any message identifier, so this is a client-side generated identifier (GUID).
Declaration
public override int GetHashCode()
Returns
| Type | Description |
|---|---|
| int |
Overrides
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).
ToLogString()
Gets a string that can be used to log the identifier/offset value.
Declaration
public string ToLogString()
Returns
| Type | Description |
|---|---|
| string | A string representing the identifier/offset value. |
Remarks
This string should contain all identifiers except the endpoint name.
ToString()
The MQTT broker doesn't provide any message identifier, so this is a client-side generated identifier (GUID).
Declaration
public override string ToString()
Returns
| Type | Description |
|---|---|
| string |
Overrides
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).
ToVerboseLogString()
Gets a string that can be used to log the identifier/offset value.
Declaration
public string ToVerboseLogString()
Returns
| Type | Description |
|---|---|
| string | A string representing the identifier/offset value. |
Remarks
This string must include the endpoint name, if the identifier value isn't unique across different endpoints.
Operators
operator ==(MqttMessageIdentifier?, MqttMessageIdentifier?)
The MQTT broker doesn't provide any message identifier, so this is a client-side generated identifier (GUID).
Declaration
public static bool operator ==(MqttMessageIdentifier? left, MqttMessageIdentifier? right)
Parameters
| Type | Name | Description |
|---|---|---|
| MqttMessageIdentifier | left | |
| MqttMessageIdentifier | right |
Returns
| Type | Description |
|---|---|
| bool |
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).
operator !=(MqttMessageIdentifier?, MqttMessageIdentifier?)
The MQTT broker doesn't provide any message identifier, so this is a client-side generated identifier (GUID).
Declaration
public static bool operator !=(MqttMessageIdentifier? left, MqttMessageIdentifier? right)
Parameters
| Type | Name | Description |
|---|---|---|
| MqttMessageIdentifier | left | |
| MqttMessageIdentifier | right |
Returns
| Type | Description |
|---|---|
| bool |
Remarks
Generating the identifier client-side might prevent some Silverback features to work properly (e.g. MaxFailedAttempts).