Skip to content

feat(telemetry): implement runtime metrics registry and /stats admin command - #19

Merged
qdiaps merged 3 commits into
masterfrom
feat/telemetry
Nov 20, 2026
Merged

qdiaps merged 3 commits into
masterfrom
feat/telemetry

Conversation

@qdiaps

@qdiaps qdiaps commented Nov 20, 2026

Copy link
Copy Markdown
Owner

Description

Implements runtime telemetry tracking and an admin /stats command to monitor bot health and request traffic:

  • Telemetry Registry (BotTelemetry): Added lock-free request counters (LongAdder, AtomicInteger) for in-flight, succeeded, rejected, failed, and ignored updates, alongside startup timestamp, monotonic uptime, JVM memory, and workDir disk space metrics.
  • Validated Snapshots (TelemetrySnapshot): Created an immutable snapshot record enforcing non-negative counters, exact request sum invariants, and resource bounds.
  • Runtime Integration: Prepared workDir on startup in Main and wired telemetry hooks across Receiver, MessageRouter, and CommandRouter.
  • Admin Reporting (/stats): Added StatsCommand to render formatted uptime, request breakdown, and resource usage for administrators.

Type of Change

  • Bug fix (non-breaking change fixing an issue)
  • New feature (non-breaking change adding functionality)
  • Breaking change (fix or feature causing existing behavior to change)
  • Documentation update
  • Refactoring / CI / Build improvements

Checklist

  • My code follows the code style of this project
  • I have run ./mvnw clean verify and all tests pass
  • My commit messages follow Conventional Commits specification

@qdiaps
qdiaps merged commit e80ecfc into master Nov 20, 2026
2 checks passed
@qdiaps
qdiaps deleted the feat/telemetry branch November 20, 2026 09:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant