Search Results for

    Show / Hide Table of Contents

    Class DynamoDBPersistenceStore

    DynamoDB version of the BasePersistenceStore. Will store idempotency data in DynamoDB.

    Inheritance
    object
    BasePersistenceStore
    DynamoDBPersistenceStore
    Implements
    IPersistenceStore
    Inherited Members
    BasePersistenceStore.PayloadValidationEnabled
    BasePersistenceStore.Configure(IdempotencyOptions, string, string)
    BasePersistenceStore.SaveSuccess(JsonDocument, object, DateTimeOffset)
    BasePersistenceStore.SaveInProgress(JsonDocument, DateTimeOffset, double?)
    BasePersistenceStore.DeleteRecord(JsonDocument, Exception)
    BasePersistenceStore.GetRecord(JsonDocument, DateTimeOffset)
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: AWS.Lambda.Powertools.Idempotency.Persistence
    Assembly: AWS.Lambda.Powertools.Idempotency.dll
    Syntax
    public class DynamoDBPersistenceStore : BasePersistenceStore, IPersistenceStore

    Methods

    DeleteRecord(string)

    Remove item from persistence store

    Declaration
    public override Task DeleteRecord(string idempotencyKey)
    Parameters
    Type Name Description
    string idempotencyKey

    idempotencyKey the key of the record

    Returns
    Type Description
    Task
    Overrides
    BasePersistenceStore.DeleteRecord(string)

    GetRecord(string)

    Retrieve item from persistence store using idempotency key and return it as a DataRecord instance.

    Declaration
    public override Task<DataRecord> GetRecord(string idempotencyKey)
    Parameters
    Type Name Description
    string idempotencyKey

    idempotencyKey the key of the record

    Returns
    Type Description
    Task<DataRecord>

    DataRecord representation of existing record found in persistence store

    Overrides
    BasePersistenceStore.GetRecord(string)
    Exceptions
    Type Condition
    IdempotencyItemNotFoundException

    Exception thrown if no record exists in persistence store with the idempotency key

    PutRecord(DataRecord, DateTimeOffset)

    Add a DataRecord to persistence store if it does not already exist with that key. Stores the given idempotency record in the DDB store. If there is an existing record that has expired - either due to the cache expiry or due to the in_progress_expiry - the record will be overwritten and the idempotent operation can continue. Note: This method writes only expiry and status information - not the results of the operation itself.

    Declaration
    public override Task PutRecord(DataRecord record, DateTimeOffset now)
    Parameters
    Type Name Description
    DataRecord record

    record DataRecord instance

    DateTimeOffset now
    Returns
    Type Description
    Task
    Overrides
    BasePersistenceStore.PutRecord(DataRecord, DateTimeOffset)
    Exceptions
    Type Condition
    IdempotencyItemAlreadyExistsException

    if a non-expired entry already exists.

    UpdateRecord(DataRecord)

    Update item in persistence store

    Declaration
    public override Task UpdateRecord(DataRecord record)
    Parameters
    Type Name Description
    DataRecord record

    DataRecord instance

    Returns
    Type Description
    Task
    Overrides
    BasePersistenceStore.UpdateRecord(DataRecord)

    Implements

    IPersistenceStore
    In this article
    Back to top Powertools for AWS Lambda (.NET) API Documentation