Private StaticcalculateCalculate memory usage delta between two snapshots.
Private StaticcategorizeCategorize performance based on duration.
StaticcreateCreate a performance timer that can be manually controlled. Useful for tracking operations that span multiple function calls.
Human-readable name for the operation
Optionalcontext: Record<string, unknown>Additional context information
PerformanceTimer instance
Private StaticformatFormat bytes into human-readable format.
Private StaticgetGet current memory usage snapshot.
StatictrackTrack operation performance with automatic logging and memory monitoring. Logs start, completion, and failure with detailed performance metrics.
Human-readable name for the operation
Async function to execute and monitor
Optionalcontext: Record<string, unknown>Additional context information
Promise that resolves with the operation result
StatictrackTrack synchronous operation performance. For operations that don't return promises but still need timing.
Human-readable name for the operation
Synchronous function to execute and monitor
Optionalcontext: Record<string, unknown>Additional context information
The operation result
Performance monitoring utilities for tracking operation timing and memory usage.