feat(telemetry): add validationsChecked recording hook in recvValidation

Wire incrementValidationsChecked() into NetworkOPs::recvValidation() so
each received network validation increments the counter.

Note: incrementJqTransOverflow() hook is deferred — JobQueue has no
explicit overflow event path; the counter is reserved for future use.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Pratik Mankawde
2026-03-31 14:04:57 +01:00
parent 45ffe8e2ec
commit 92607805c3

View File

@@ -2446,6 +2446,8 @@ bool
NetworkOPsImp::recvValidation(std::shared_ptr<STValidation> const& val, std::string const& source)
{
JLOG(m_journal.trace()) << "recvValidation " << val->getLedgerHash() << " from " << source;
if (auto* mr = registry_.getMetricsRegistry())
mr->incrementValidationsChecked();
std::unique_lock lock(validationsMutex_);
BypassAccept bypassAccept = BypassAccept::no;