/** * Simple RPC call counter for diagnostics. * Incremented on each RPC request, read by diagnostics.stats handler. */ let _rpcCallCount = 0; let _droppedEvents = 0; export function incrementRpcCallCount(): void { _rpcCallCount++; } export function incrementDroppedEvents(): void { _droppedEvents++; } export function getRpcCallCount(): number { return _rpcCallCount; } export function getDroppedEvents(): number { return _droppedEvents; }