Skip to content

geneva: add server-side packet-manipulation telemetry keys - #23

Merged
reflog merged 1 commit into
mainfrom
reflog/geneva-telemetry-keys
Aug 31, 2026
Merged

reflog merged 1 commit into
mainfrom
reflog/geneva-telemetry-keys

Conversation

@reflog

@reflog reflog commented Aug 31, 2026 •

Copy link
Copy Markdown
Contributor

Adds a Geneva group to custom.go for the geneva-server NFQUEUE sidecar (getlantern/geneva-server#1, getlantern/engineering#3859).

The sidecar previously exposed its counters only through a pull-only GET /metrics control endpoint. It now exports them as OTLP metrics to the box's local collector, so lantern-cloud reads them from SigNoz instead of SSH-ing to the box. These are the keys for that export.

Metric names — engine packet/byte counters, outcome and verdict breakdowns, reinjection results, overhead ratios, strategy-swap count, uptime, and geneva.censor.inbound_tcp.

geneva.censor.inbound_tcp is the load-bearing one: clients behind a censor cannot report a connection that never completed, so the inbound syn-versus-data ratio per market is the only available evidence that a test box's IP has been burned — which is the binding cost of GA exploration (getlantern/engineering#3869).

Attribute keys — geneva.mode, geneva.outcome, geneva.verdict, geneva.reinjection, geneva.tcp_event. Market is labelled with the existing standard geo.country.iso_code rather than a new key, so it correlates with client geo.

No key carries a strategy DNA or candidate identifier: candidate identity is attributed through server-issued opaque tokens in the brain's own tables, and a per-candidate label would both leak it into SigNoz and make cardinality unbounded in the GA's population size. Noted in a comment on the group.

Summary by CodeRabbit

  • New Features
    • Added telemetry definitions for Geneva packet-processing metrics, including traffic, errors, outcomes, overhead, verdicts, reinjections, strategy changes, uptime, and TCP activity.
    • Added standardized telemetry attributes for Geneva modes, outcomes, verdicts, reinjection status, and TCP events.

Copilot AI lite review requested due to automatic review settings August 31, 2026 12:51
@coderabbitai

coderabbitai Bot commented Aug 31, 2026 •

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 2e44e597-cac6-4ebd-b777-57bf1706f9cd

📥 Commits

Reviewing files that changed from the base of the PR and between 318c52c and 5992413.

📒 Files selected for processing (1)
  • custom.go

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.


📝 Walkthrough

Walkthrough

The change adds Geneva metric-name constants and typed attribute keys to custom.go. The conventions cover packet handling, outcomes, verdicts, reinjection, strategy swaps, uptime, and TCP events.

Changes

Geneva telemetry conventions

Layer / File(s) Summary
Geneva telemetry contract
custom.go
Adds string constants for Geneva metrics and attribute.Key constants for Geneva telemetry attributes. The conventions exclude strategy DNA and candidate identifiers from telemetry.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Merge Risk: ⚪ Minimal · up to 59924

This PR adds localized Geneva telemetry names and attributes without any identified merge-blocking risk; it is merge-ready after normal checks and review.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: adding Geneva server-side packet-manipulation telemetry keys.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1 files.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch reflog/geneva-telemetry-keys

Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds new Lantern-specific semantic convention constants for the geneva-server NFQUEUE sidecar so it can export its packet-manipulation metrics via OTLP with stable metric names and attribute keys (without introducing high-cardinality or identity-leaking labels).

Changes:

  • Added a new Geneva metric-name constant group (engine counters, outcomes/verdicts, overhead ratios, reinjections, swaps, uptime, and geneva.censor.inbound_tcp).
  • Added a new Geneva attribute-key constant group (geneva.mode, geneva.outcome, geneva.verdict, geneva.reinjection, geneva.tcp_event) with value semantics documented inline.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@reflog
reflog requested a lite review from Copilot August 31, 2026 13:04
@reflog
reflog merged commit c31b810 into main Aug 31, 2026
3 checks passed

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.

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.

2 participants