Type alias DidResolverCacheLevelParams

DidResolverCacheLevelParams: {
    db?: AbstractLevel<string | Buffer | Uint8Array, string, string>;
    location?: string;
    ttl?: string;
}

Configuration parameters for creating a LevelDB-based cache for DID resolution results.

Allows customization of the underlying database instance, storage location, and cache time-to-live (TTL) settings.

Type declaration

  • Optional db?: AbstractLevel<string | Buffer | Uint8Array, string, string>

    Optional. An instance of AbstractLevel to use as the database. If not provided, a new LevelDB instance will be created at the specified location.

  • Optional location?: string

    Optional. The file system path or IndexedDB name where the LevelDB store will be created. Defaults to 'DATA/DID_RESOLVERCACHE' if not specified.

  • Optional ttl?: string

    Optional. The time-to-live for cache entries, expressed as a string (e.g., '1h', '15m'). Determines how long a cache entry should remain valid before being considered expired. Defaults to '15m' if not specified.