Show / Hide Table of Contents

    Class ProducerEndpoint

    Represents a message broker endpoint to produce to (such as a Kafka topic or RabbitMQ queue or exchange).

    Inheritance
    object
    Endpoint
    ProducerEndpoint
    KafkaProducerEndpoint
    MqttProducerEndpoint
    RabbitProducerEndpoint
    Implements
    IProducerEndpoint
    IEndpoint
    Inherited Members
    Endpoint.DefaultSerializer
    Endpoint.DisplayName
    Endpoint.Name
    Endpoint.FriendlyName
    Endpoint.Serializer
    Endpoint.Encryption
    Endpoint.MessageValidationMode
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Silverback.Messaging
    Assembly: Silverback.Integration.dll
    Syntax
    public abstract class ProducerEndpoint : Endpoint, IProducerEndpoint, IEndpoint

    Constructors

    | Improve this doc View source

    ProducerEndpoint(Func<IOutboundEnvelope, IServiceProvider, string?>)

    Initializes a new instance of the ProducerEndpoint class.

    Declaration
    protected ProducerEndpoint(Func<IOutboundEnvelope, IServiceProvider, string?> nameFunction)
    Parameters
    Type Name Description
    Func<IOutboundEnvelope, IServiceProvider, string> nameFunction

    The function returning the topic name for the message being produced. If the function returns null the message will not be produced.

    | Improve this doc View source

    ProducerEndpoint(Func<IOutboundEnvelope, string?>)

    Initializes a new instance of the ProducerEndpoint class.

    Declaration
    protected ProducerEndpoint(Func<IOutboundEnvelope, string?> nameFunction)
    Parameters
    Type Name Description
    Func<IOutboundEnvelope, string> nameFunction

    The function returning the topic name for the message being produced. If the function returns null the message will not be produced.

    | Improve this doc View source

    ProducerEndpoint(string)

    Initializes a new instance of the ProducerEndpoint class.

    Declaration
    protected ProducerEndpoint(string name)
    Parameters
    Type Name Description
    string name

    The endpoint name.

    | Improve this doc View source

    ProducerEndpoint(string, Func<IOutboundEnvelope, string[]>)

    Initializes a new instance of the ProducerEndpoint class.

    Declaration
    protected ProducerEndpoint(string nameFormat, Func<IOutboundEnvelope, string[]> argumentsFunction)
    Parameters
    Type Name Description
    string nameFormat

    The endpoint name format string that will be combined with the arguments returned by the argumentsFunction using a string.Format.

    Func<IOutboundEnvelope, string[]> argumentsFunction

    The function returning the arguments to be used to format the string.

    | Improve this doc View source

    ProducerEndpoint(Type)

    Initializes a new instance of the ProducerEndpoint class.

    Declaration
    protected ProducerEndpoint(Type resolverType)
    Parameters
    Type Name Description
    Type resolverType

    The type of the IProducerEndpointNameResolver to be used to resolve the actual endpoint name.

    Properties

    | Improve this doc View source

    Chunk

    Gets or sets the message chunking settings. This option can be used to split large messages into smaller chunks.

    Declaration
    public ChunkSettings? Chunk { get; set; }
    Property Value
    Type Description
    ChunkSettings
    | Improve this doc View source

    MessageEnrichers

    Gets or sets the collection of IOutboundMessageEnricher to be used to enrich the outbound message.

    Declaration
    public ICollection<IOutboundMessageEnricher> MessageEnrichers { get; set; }
    Property Value
    Type Description
    ICollection<IOutboundMessageEnricher>
    | Improve this doc View source

    Strategy

    Gets or sets the strategy to be used to produce the messages. If no strategy is specified, the messages will be sent to the message broker directly.

    Declaration
    public IProduceStrategy Strategy { get; set; }
    Property Value
    Type Description
    IProduceStrategy

    Methods

    | Improve this doc View source

    BaseEquals(Endpoint?)

    Determines whether the specified Endpoint is equal to the current Endpoint.

    Declaration
    protected override bool BaseEquals(Endpoint? other)
    Parameters
    Type Name Description
    Endpoint other

    The object to compare with the current object.

    Returns
    Type Description
    bool

    Returns a value indicating whether the other object is equal to the current object.

    Overrides
    Endpoint.BaseEquals(Endpoint?)
    | Improve this doc View source

    GetActualName(IOutboundEnvelope, IServiceProvider)

    Gets the actual target endpoint name for the message being produced.

    Declaration
    public string? GetActualName(IOutboundEnvelope envelope, IServiceProvider serviceProvider)
    Parameters
    Type Name Description
    IOutboundEnvelope envelope

    The envelope containing the message being produced.

    IServiceProvider serviceProvider

    The IServiceProvider in the current scope.

    Returns
    Type Description
    string

    The actual name of the endpoint to be produced to.

    | Improve this doc View source

    Validate()

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

    Declaration
    public override void Validate()
    Overrides
    Endpoint.Validate()

    Implements

    IProducerEndpoint
    IEndpoint
    • Improve this doc
    • View source
    GitHub E-Mail
    ↑ Back to top © 2020 Sergio Aquilini