Fix source time prom metric - #677
Conversation
|
Caution Review failedThe pull request is closed. WalkthroughAdjusted promCounter selection in trackNewStatus to switch on the current sourceManager.status (previous status) rather than the incoming newStatus, then increments the counter, resets statusStart, and updates status to newStatus. Changes
Sequence Diagram(s)sequenceDiagram
participant Caller
participant SourceManager
participant Prometheus
Caller->>SourceManager: trackNewStatus(newStatus)
activate SourceManager
Note over SourceManager: Select promCounter using previous status (sourceManager.status)
SourceManager->>Prometheus: promCounter.labels(chainId).inc()
SourceManager->>SourceManager: statusStart <- now
SourceManager->>SourceManager: status <- newStatus
deactivate SourceManager
Estimated code review effort🎯 2 (Simple) | ⏱️ ~7 minutes Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Used the wrong source 😅
Summary by CodeRabbit