/** * Redis World Implementation * * A production-ready World implementation using Redis for storage, * BullMQ for queue processing, and Redis Streams for real-time output. */ import type { World } from '@workflow/world'; import { Redis } from 'ioredis'; import { type QueueConfig } from './queue.js'; import { type RedisStorageConfig } from './storage.js'; import { type StreamerConfig } from './streamer.js'; /** * Configuration for the Redis world. */ export interface RedisWorldConfig extends QueueConfig, StreamerConfig, RedisStorageConfig { /** * Redis connection string. * If not provided, uses WORKFLOW_REDIS_URI environment variable. * Default: 'redis://localhost:6379' */ redisUrl?: string; /** * Pre-existing ioredis client to use. * If provided, redisUrl is ignored. */ client?: Redis; } /** * Creates a Redis World instance. * * This implementation uses Redis for: * - Storage: Runs, steps, events, and hooks (using Hashes and Sorted Sets) * - Queue: BullMQ with native deduplication and retries * - Streaming: Redis Streams with Pub/Sub for real-time output */ export declare function createWorld(config?: RedisWorldConfig): World; export default createWorld; export { type QueueConfig } from './queue.js'; export { type StreamerConfig } from './streamer.js'; export { type RedisStorageConfig } from './storage.js'; //# sourceMappingURL=index.d.ts.map