import Redis from "ioredis"; import { ICacheStorage } from "./storage-interface"; /** * Redis cache storage (implements cache signatures) * All items are stored in redis and are immutable after retrieval * because they might be shared between threads to prevent data corruption */ export declare class RedisStorage implements ICacheStorage { private cache; /** * Create a wrapper class for ioredis package * @param redisInstance ioredis instance */ constructor(redisInstance: Redis); /** * Retrieves cache key * @param key * @returns */ get(key: string, immutable?: boolean): Promise; /** * Sets cache key * @param key key to be set * @param ttlMilliseconds milliseconds to keep in cache * @param value value to store */ set(key: string, ttlMilliseconds: number, value: T, immutable?: boolean): Promise; /** * * @param key * @returnsv Promise */ evict(key: string): Promise; } //# sourceMappingURL=redis.d.ts.map