/** * Smart Tiered Cache - Main Application Entry Point * Wires all components together and provides startup/shutdown functionality * Requirements: 1.13, 9.8, 10.1, 10.2 */ import { ConfigManager, type CacheConfig } from './config/index.js'; import { RAMTier, SSDTier, DBTier } from './storage/index.js'; import { AccessTracker } from './tracking/index.js'; import { EvictionPolicy } from './eviction/index.js'; import { TierManager } from './tier/index.js'; import { CacheEngine, ListOperations, HashOperations, SetOperations } from './cache/index.js'; import { RedisServer, CommandRouter } from './protocol/index.js'; import { PredictionEngine } from './prediction/index.js'; import { DashboardService } from './dashboard/index.js'; export { ConfigManager, type CacheConfig } from './config/index.js'; export { RAMTier, SSDTier, DBTier, type StorageTier, type TierConfig } from './storage/index.js'; export { AccessTracker, type KeyAccessInfo, type AccessTrackerConfig } from './tracking/index.js'; export { EvictionPolicy, type PolicyType, type EvictionHint } from './eviction/index.js'; export { TierManager, type TierThresholds, type TierStats, type MovementResult } from './tier/index.js'; export { CacheEngine, type CacheEngineConfig, type CacheEngineDependencies, ListOperations, HashOperations, SetOperations, SnapshotManager } from './cache/index.js'; export { RedisServer, CommandRouter, RespParser, RespSerializer } from './protocol/index.js'; export { PredictionEngine, type PredictionEngineConfig, type PredictionResult } from './prediction/index.js'; export { DashboardService, type DashboardMetrics, type TierDistribution, type CostMetrics } from './dashboard/index.js'; export { type Tier, type CacheValue, type KeyMetadata, type KeyIndexEntry, type SetOptions } from './types/index.js'; /** * Application instance containing all initialized components */ export interface SmartTieredCacheApp { config: CacheConfig; configManager: ConfigManager; ramTier: RAMTier; ssdTier: SSDTier; dbTier: DBTier; accessTracker: AccessTracker; evictionPolicy: EvictionPolicy; tierManager: TierManager; cacheEngine: CacheEngine; predictionEngine: PredictionEngine; redisServer: RedisServer; commandRouter: CommandRouter; dashboardService: DashboardService; listOps: ListOperations; hashOps: HashOperations; setOps: SetOperations; } /** * Options for starting the application */ export interface StartOptions { /** Path to configuration file (optional) */ configPath?: string; /** Override configuration values (optional) */ configOverrides?: Partial; /** Skip starting Redis server (useful for testing) */ skipRedisServer?: boolean; /** Skip starting Dashboard service (useful for testing) */ skipDashboard?: boolean; } /** * Initialize and start the Smart Tiered Cache application. * * This function: * 1. Loads configuration from file and environment variables * 2. Initializes all storage tiers (RAM, SSD, DB) * 3. Initializes AccessTracker, EvictionPolicy, TierManager * 4. Initializes CacheEngine with all dependencies * 5. Initializes PredictionEngine and wires to TierManager * 6. Initializes RedisServer with CommandRouter * 7. Initializes DashboardService * 8. Starts all services * * Requirements: 1.13, 9.8, 10.1, 10.2 * * @param options - Startup options * @returns The initialized application instance */ export declare function start(options?: StartOptions): Promise; /** * Gracefully shutdown the application. * * This function: * 1. Stops accepting new connections * 2. Waits for pending operations to complete * 3. Persists RAM tier data * 4. Closes all storage tiers * * @param app - The application instance to shutdown */ export declare function shutdown(app: SmartTieredCacheApp): Promise; /** * Main entry point when running as a standalone application. * Sets up signal handlers and starts the cache. */ export declare function main(): Promise; //# sourceMappingURL=index.d.ts.map