DWS Packages
    Preparing search index...

    In-memory key-value store adapter with automatic cleanup of expired entries.

    Provides a memory-based implementation of KvStore with TTL support and automatic background cleanup of expired entries.

    Hierarchy (View Summary)

    Index

    Constructors

    Methods

    • Type Parameters

      • T = unknown

      Parameters

      • key: string
      • value: T
      • OptionalttlSec: number

      Returns void

    • Validates an increment/decrement amount and throws an exception if it's invalid.

      Parameters

      • amount: number

        The amount to validate.

      Returns void

      (Exception) - If the amount is invalid.

    • Validates a key string and throws an exception if it's invalid.

      Parameters

      • key: string

        The key to validate.

      Returns void

      (Exception) - If the key is invalid.

    • Validates a TTL value and throws an exception if it's invalid.

      Parameters

      • ttlSec: number | undefined

        The TTL value to validate.

      Returns void

      (Exception) - If the TTL is invalid.