mirror of
https://github.com/woodchen-ink/proxy-go.git
synced 2025-07-18 08:31:55 +08:00
- Introduced safe type conversion functions for memory usage, status code stats, top paths, and recent requests to prevent panics when accessing metrics data. - Updated MetricsHandler to utilize these safe functions, improving the robustness of metrics handling. - Refactored GetStats method in Collector to ensure all fields are initialized and to streamline the retrieval of metrics data. - Enhanced the overall structure of metrics data for better clarity and reliability in reporting.