Search Results for

    Show / Hide Table of Contents

    Class ZaminInboxStore

    Implements IInboxStore using Zamin's native InboxMessage table and Zamin.Infra.Data.Sql.Commands.BaseCommandDbContext.

    Inheritance
    object
    ZaminInboxStore
    Implements
    IInboxStore
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Chapar.Zamin.Outbox.Inbox
    Assembly: Chapar.Zamin.Outbox.dll
    Syntax
    public sealed class ZaminInboxStore : IInboxStore

    Constructors

    | Edit this page View Source

    ZaminInboxStore(BaseCommandDbContext)

    Initializes a new instance of the ZaminInboxStore class.

    Declaration
    public ZaminInboxStore(BaseCommandDbContext dbContext)
    Parameters
    Type Name Description
    BaseCommandDbContext dbContext

    The Zamin command database context.

    Methods

    | Edit this page View Source

    MarkAsProcessedAsync(InboxMessage, CancellationToken)

    Marks a previously reserved message as completely processed. Called only after the handler has finished without exception.

    Declaration
    public Task<bool> MarkAsProcessedAsync(InboxMessage message, CancellationToken cancellationToken = default)
    Parameters
    Type Name Description
    InboxMessage message

    The inbox message record that should be updated.

    CancellationToken cancellationToken

    Cancellation token.

    Returns
    Type Description
    Task<bool>

    true if the message was marked for the first time; false if it was already processed.

    | Edit this page View Source

    TryReserveAsync(string, string, CancellationToken)

    Attempts to atomically reserve an incoming message for processing. When the method returns true the caller is the exclusive processor of the message; when it returns false the message has already been reserved by another consumer.

    Declaration
    public Task<bool> TryReserveAsync(string messageId, string consumerTypeName, CancellationToken cancellationToken = default)
    Parameters
    Type Name Description
    string messageId

    The unique identifier of the incoming message.

    string consumerTypeName

    The fully qualified type name of the consumer that will handle the message.

    CancellationToken cancellationToken

    Cancellation token.

    Returns
    Type Description
    Task<bool>

    true if the reservation was successful; otherwise false.

    Implements

    IInboxStore
    • Edit this page
    • View Source
    In this article
    Back to top Copyright © 2026