Skip to main content
Deno 2 is finally here πŸŽ‰οΈ
Learn more
Module

x/redis/connection.ts>RedisConnection

πŸ¦• Redis client for Deno πŸ•
Very Popular
Latest
class RedisConnection
implements Connection
import { RedisConnection } from "https://deno.land/x/redis@v0.34.0/connection.ts";

Constructors

new
RedisConnection(
hostname: string,
port: number | string,
options: RedisConnectionOptions,
)

Properties

private
_isClosed: boolean
private
_isConnected: boolean
private
backoff: Backoff
private
commandQueue: PendingCommand[]
private
readonly
hostname: string
private
maxRetryCount: number
private
readonly
port: number | string
readonly
isClosed: boolean
readonly
isConnected: boolean
readonly
isRetriable: boolean
name: string | null

Methods

private
authenticate(username: string | undefined, password: string): Promise<void>
private
enqueueCommand(command: PendingCommand)
private
isManuallyClosedByUser(): boolean
private
selectDb(db?: number | undefined): Promise<void>
connect(): Promise<void>

Connect to Redis server

reconnect(): Promise<void>
sendCommand(
command: string,
args?: Array<RedisValue>,
options?: SendCommandOptions,
): Promise<RedisReply>
[kUnstablePipeline](commands: Array<Command>)
[kUnstableReadReply](returnsUint8Arrays?: boolean): Promise<RedisReply>
[kUnstableWriteCommand](command: Command): Promise<void>