Skip to content

fix(otel): use the /otel Cloud endpoint base - #903

Merged
NiveditJain merged 2 commits into
mainfrom
fix/otel-endpoint-path
Oct 15, 2026
Merged

NiveditJain merged 2 commits into
mainfrom
fix/otel-endpoint-path

Conversation

@chhhee10

@chhhee10 chhhee10 commented Oct 15, 2026 •

Copy link
Copy Markdown
Member

Companion PR: FailproofAI/agenteye#1080

Summary

Follow-up to merged #880. Direct agent configuration and otel env now use <cloud>/otel. Codex gets the complete <cloud>/otel/v1/logs URL. The daemon keeps standard local /v1/* receivers and SDK spool metadata, and forwards upstream to /otel/v1/* exactly once.

Cloud credentials and non-OTLP API URLs are unchanged. Existing beta direct-agent settings are reported as not managed until rewritten. After upgrading, disable/re-enable OTel and restart the agent to load the new settings.

Validation

  • 44 OTel configuration/status tests.
  • 9 relay unit tests including all three signals and credential-URL normalization.
  • 5 real daemon relay e2e tests with isolated temporary homes, including SDK spool delivery.
  • Lint and TypeScript passed; 1063 MDX pages parsed cleanly.

Rollout

Requires the companion AgentEye namespace PR to be deployed first. Generic Collector endpoint: <cloud>/otel; per-signal endpoint: <cloud>/otel/v1/<signal>. No compatibility aliases requested.

Version stays 1.0.11. No release, publish or deploy performed. Public usage docs and CHANGELOG are included. Existing otel_enabled/otel_disabled telemetry remains unchanged and covers the setup actions; no new customer data is collected.

Hermes review

Field Value
Status Approved
Reviewed commit f78d19e73bc7092ffa32c1db6b4b0f0d5245f5e1
Policy revision 1d8f31d926828f3bae215c58f5b35baa44acbff0
Model gpt-5.6-terra
Duration 464s
Updated 2026-10-15T13:37:03.025842757+00:00

Summary

No correctness, security, or compatibility defect found. Cloud-bound OTLP configuration and relay forwarding consistently target /otel, while local receivers retain standard /v1/<signal> paths.

Changes

  • Updates direct agent setup and otel env to use the Cloud OTLP base URL <origin>/otel; Codex and per-signal variables receive full signal URLs.
  • Updates the daemon relay to keep local spool metadata and listeners on /v1/* while forwarding upstream to /otel/v1/*.
  • Adds regression coverage and documents the endpoint migration and required reconfiguration.

Validation

  • Passed docker run --rm --network none -v /review/input/workspace:/repo:ro -w /repo oven/bun:latest bun build src/hooks/otel-cli.ts src/hooks/otel-writers.ts --outdir /tmp/otel-syntax --external '*' — Both changed TypeScript entry points bundled successfully in an isolated container. (0s)
  • Skipped docker run ... bun install --frozen-lockfile --ignore-scripts && bunx vitest run __tests__/hooks/otel.test.ts --reporter=verbose — A clean dependency install remained stalled for over two minutes without materializing dependencies, so the targeted Vitest suite could not start in this isolated environment. (157s)

Findings

None.

Open questions

None.

Policy overrides

None.

Summary by CodeRabbit

  • Bug Fixes

    • OpenTelemetry data sent directly to Cloud or through the relay now uses the /otel endpoint. Local relay paths remain unchanged.
    • Agent status checks now recognize existing Cloud settings against the updated endpoint.
  • Documentation

    • Clarified Cloud base and per-signal endpoint formats, with updated configuration examples.
    • Added an upgrade instruction to disable and re-enable each agent’s OpenTelemetry setup to update older settings.

Additional local verification: 363 e2e tests passed (one skipped), and Rust clippy passed for the collector/daemon. The broad unit run had one timing-only redaction-cost failure under parallel load (8432 passed, 10 skipped); its seven-test file passed unchanged when rerun alone. The final-head CI unit matrices all passed.

@github-actions

Copy link
Copy Markdown
Contributor

Thanks @chhhee10 for your contribution to Failproof AI! 🙌

We'd love to discuss your PR and welcome you to our community.

Discord: https://discord.befailproof.ai/
Reddit: https://www.reddit.com/r/failproofai/

@coderabbitai

coderabbitai Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 5b9effcc-8145-4b8d-be3f-909a20d248b4
📥 Commits

Reviewing files that changed from the base of the PR and between 2ed4c8c and f78d19e.

📒 Files selected for processing: 8
  • CHANGELOG.md
  • __tests__/hooks/otel.test.ts
  • crates/failproofaid/tests/otlp_relay_e2e.rs
  • crates/fpai-collect/src/otlp.rs
  • docs/agenteye/opentelemetry.mdx
  • docs/reference/otel.mdx
  • src/hooks/otel-cli.ts
  • src/hooks/otel-writers.ts

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.

📝 Walkthrough

Cloud OTLP destinations now use /otel as the base path. Agent settings and relay forwarding append signal paths beneath it. Local relay destinations remain unchanged. Documentation, changelog entries, and tests reflect the updated paths.

Changes: Cloud OTLP path

Layer / File(s) Summary
Agent destination configuration
src/hooks/otel-writers.ts, src/hooks/otel-cli.ts, __tests__/hooks/otel.test.ts, docs/agenteye/opentelemetry.mdx, docs/reference/otel.mdx, CHANGELOG.md
Shared helpers construct Cloud destinations with /otel and preserve local relay URLs. Agent enablement, environment output, and status checks use the destination helpers. Tests and documentation cover the updated paths and older managed settings.
Relay upstream forwarding
crates/fpai-collect/src/otlp.rs, crates/failproofaid/tests/otlp_relay_e2e.rs
The relay derives a Cloud base URL with /otel and appends each signal path when forwarding. Tests check the resulting request paths and delivery behavior.

Priority: ➖ Normal

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Bug fix

Merge Risk: ⚪ Minimal · up to f78d1

The endpoint paths appear consistent across configuration, forwarding, tests, and documentation; the change is ready for normal merge checks.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 38.46% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 13 functions across 5 files. (3 skipped: … Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
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.
Title check Passed The title clearly identifies the main change: updating the Cloud OpenTelemetry endpoint base to /otel.
Description check Passed The description is detailed and covers the change, motivation, validation, rollout requirements, compatibility behavior, and documentation. It does not use the repository template headings or checkbox…
Full details: Docstring Coverage

Explanation

Docstring coverage is 38.46% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 13 functions across 5 files. (3 skipped: 3 unsupported.)

  • Fix all pre-merge checks with AI
✨ Finishing Touches: 💡 1
📝 Generate docstrings: 💡
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

❤️ Share

I’m a rabbit with a path to trace,
/otel leads to the Cloud’s new place.
Logs and metrics follow through,
Traces join the signal queue.
Local paths stay as they were,
I nibble greens and hop with care.

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

@hermes-exosphere

Copy link
Copy Markdown
Contributor

Hermes

Status Reviewing
Verdict Not reviewed yet
Head f78d19e73bc7
Rounds 0 of 5

No summary yet.

What this changes

No component map for this revision.

Rounds

No review has finished on this pull request yet.

Findings

Nothing raised yet.


@hermes-exosphere help lists every command. This comment is maintained in place — I rewrite it after each review rather than posting a new one.

@hermes-exosphere

Copy link
Copy Markdown
Contributor

Hermes

Status Reviewed
Verdict Approved
Head f78d19e73bc7
Rounds 0 of 5

No correctness, security, or compatibility defect found. Cloud-bound OTLP configuration and relay forwarding consistently target /otel, while local receivers retain standard /v1/<signal> paths.

What this changes

flowchart LR
    n0OTELCLIconfiguration["~ OTEL CLI configuration"]
    n1AgentOTELsettingswriters["~ Agent OTEL settings writers"]
    n2LocalOTLPrelay["~ Local OTLP relay"]
    n3CloudOTLPingestAPI["Cloud OTLP ingest API"]
    n4OTELregressiontests["~ OTEL regression tests"]
    n5OTELuserdocumentation["~ OTEL user documentation"]
    n0OTELCLIconfiguration -- "constructs exporter settings" --> n1AgentOTELsettingswriters
    n1AgentOTELsettingswriters -- "uses /otel signal endpoints" --> n3CloudOTLPingestAPI
    n1AgentOTELsettingswriters -- "uses local /v1 endpoints" --> n2LocalOTLPrelay
    n2LocalOTLPrelay -- "forwards /otel/v1 batches" --> n3CloudOTLPingestAPI
    n4OTELregressiontests -- "asserts generated endpoints" --> n0OTELCLIconfiguration
    n4OTELregressiontests -- "asserts upstream paths" --> n2LocalOTLPrelay
Loading

Rounds

Round Reviewed Commits in this round Verdict
0 f78d19e73bc7 56f0ceebefb9 f78d19e73bc7 Approved

Findings

Nothing raised yet.


@hermes-exosphere help lists every command. This comment is maintained in place — I rewrite it after each review rather than posting a new one.

@hermes-exosphere hermes-exosphere 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.

Hermes found no blocking issues in this revision.

@NiveditJain
NiveditJain merged commit a9b27ef into main Oct 15, 2026
35 checks passed
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.

3 participants