Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/keydb/redis.ts>RedisAdapter

Simple Key-value storage module with support for multiple database backends.
Latest
class RedisAdapter
implements Adapter
import { RedisAdapter } from "https://deno.land/x/keydb@1.0.0/redis.ts";

Constructors

new
RedisAdapter(client: Redis, table?: string)

Properties

db: Redis
table: string

Methods

clear(namespace?): Promise<this>
delete(key: string, namespace?): Promise<boolean>
deleteExpired(_namespace?): Promise<void>
get(key: string, namespace?): Promise<KeydbFields | undefined>
getPrefixedKey(key: string, ns?)
has(key: string, namespace?): Promise<boolean>
keys(namespace?): Promise<string[]>
set(
key: string,
value: any,
namespace?,
ttl?,
): Promise<this>

Static Methods

connect(dbOptions: RedisConnectOptions, table?: string)

Connect to a Postgres Database and create Adapter.