first refactor
This commit is contained in:
parent
1f5dac28c7
commit
588f666943
84 changed files with 996 additions and 1062 deletions
|
|
@ -3,6 +3,7 @@ import type { CacheProvider } from '@stock-bot/cache';
|
|||
import { createCache } from '@stock-bot/cache';
|
||||
import type { HandlerRegistry } from '@stock-bot/handler-registry';
|
||||
import { getLogger } from '@stock-bot/logger';
|
||||
import type { LoggerLike as Logger } from '@stock-bot/logger';
|
||||
import Redis from 'ioredis';
|
||||
import { Queue, type QueueWorkerConfig } from './queue';
|
||||
import { QueueRateLimiter } from './rate-limiter';
|
||||
|
|
@ -19,16 +20,6 @@ import type {
|
|||
} from './types';
|
||||
import { getRedisConnection } from './utils';
|
||||
|
||||
// Logger interface for type safety
|
||||
interface Logger {
|
||||
info(message: string, meta?: Record<string, unknown>): void;
|
||||
error(message: string, meta?: Record<string, unknown>): void;
|
||||
warn(message: string, meta?: Record<string, unknown>): void;
|
||||
debug(message: string, meta?: Record<string, unknown>): void;
|
||||
trace(message: string, meta?: Record<string, unknown>): void;
|
||||
child?(name: string, context?: Record<string, unknown>): Logger;
|
||||
}
|
||||
|
||||
/**
|
||||
* QueueManager provides unified queue and cache management with service discovery
|
||||
* Handles both local and cross-service queue operations
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue