@ahmedhegazee/nestjs-telescope
Version:
Advanced observability and monitoring solution for NestJS applications with ML-powered analytics, enterprise features, and production-ready scaling
47 lines (46 loc) • 2.22 kB
TypeScript
import { OnModuleInit } from '@nestjs/common';
import { ModuleRef } from '@nestjs/core';
import { TelescopeConfig } from '../core/interfaces/telescope-config.interface';
import { TelescopeEntry } from '../core/interfaces/telescope-entry.interface';
import { EnhancedEntryManagerService } from '../core/services/enhanced-entry-manager.service';
import { WatcherInterface, WatcherMetadata, WatcherRegistryStatistics, WatcherHealthStatus } from './interfaces/watcher.interface';
export declare class WatcherRegistryService implements OnModuleInit {
private readonly moduleRef;
private readonly entryManager;
private readonly config;
private readonly logger;
private watchers;
private watcherMetadata;
private dependencyGraph;
private initialized;
constructor(moduleRef: ModuleRef, entryManager: EnhancedEntryManagerService, config: TelescopeConfig);
onModuleInit(): Promise<void>;
register(watcher: WatcherInterface, metadata?: Partial<WatcherMetadata>): void;
unregister(name: string): boolean;
enable(name: string): Promise<void>;
disable(name: string): Promise<void>;
enableAll(): Promise<void>;
disableAll(): Promise<void>;
restart(name: string): Promise<void>;
getWatcher(name: string): WatcherInterface | undefined;
getWatcherMetadata(name: string): WatcherMetadata | undefined;
getAllWatchers(): WatcherInterface[];
getEnabledWatchers(): WatcherInterface[];
getDisabledWatchers(): WatcherInterface[];
getWatchersByTag(tag: string): WatcherInterface[];
getStatistics(): WatcherRegistryStatistics;
processEntry(entry: TelescopeEntry, watcherName?: string): Promise<void>;
processBatch(entries: TelescopeEntry[], watcherName?: string): Promise<void>;
healthCheck(): Promise<WatcherHealthStatus>;
private discoverWatchers;
private buildDependencyGraph;
private initializeWatchers;
private getSortedWatchers;
private getDependents;
cleanup(): Promise<void>;
updateWatcherConfig(name: string, config: Partial<WatcherMetadata>): Promise<void>;
isInitialized(): boolean;
hasWatcher(name: string): boolean;
getWatcherCount(): number;
getEnabledWatcherCount(): number;
}