Skip to content

feat(output): add basic opentelemetry output#971

Draft
Molter73 wants to merge 4 commits into
mainfrom
mauro/feat/otel-output
Draft

feat(output): add basic opentelemetry output#971
Molter73 wants to merge 4 commits into
mainfrom
mauro/feat/otel-output

Conversation

@Molter73

@Molter73 Molter73 commented Jul 2, 2026

Copy link
Copy Markdown
Collaborator

Description

This output allows exporting file activity events as opentelemetry logs via otlp to be collected by compatible systems.

TODO:

  • Add integration tests
  • Add docs on how to use this output

Checklist

  • Patch has a change log entry OR does not need one.
  • Investigated and inspected CI test results
  • Updated documentation accordingly

Automated testing

  • Added unit tests
  • Added integration tests
  • Added regression tests

If any of these don't apply, please comment below.

Testing Performed

TBD

@coderabbitai

coderabbitai Bot commented Jul 2, 2026

Copy link
Copy Markdown

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: CHILL

Plan: Enterprise

Run ID: 04a40c8e-51c6-466c-91d2-e24980bbf7f8

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch mauro/feat/otel-output

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

@codecov-commenter

codecov-commenter commented Jul 2, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 27.18447% with 75 lines in your changes missing coverage. Please review.
✅ Project coverage is 33.99%. Comparing base (baebc56) to head (3803d50).

Files with missing lines Patch % Lines
fact/src/output/mod.rs 0.00% 29 Missing ⚠️
fact/src/output/grpc.rs 0.00% 18 Missing ⚠️
fact/src/config/reloader.rs 0.00% 12 Missing ⚠️
fact/src/output/stdout.rs 0.00% 6 Missing ⚠️
fact/src/config/mod.rs 84.84% 5 Missing ⚠️
fact/src/metrics/mod.rs 0.00% 4 Missing ⚠️
fact/src/lib.rs 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #971      +/-   ##
==========================================
+ Coverage   33.85%   33.99%   +0.14%     
==========================================
  Files          21       21              
  Lines        2812     2871      +59     
  Branches     2812     2871      +59     
==========================================
+ Hits          952      976      +24     
- Misses       1857     1892      +35     
  Partials        3        3              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Molter73 added 2 commits July 3, 2026 12:15
This output allows exporting file activity events as opentelemetry logs
via otlp to be collected by compatible systems.

TODO:
* Add feature flag
* Add configuration
* Add integration tests
* Add docs on how to use this output
@Molter73 Molter73 force-pushed the mauro/feat/otel-output branch from 486adb1 to c2d0d32 Compare July 3, 2026 12:56
Molter73 added 2 commits July 3, 2026 16:32
The new way for output components to resubscribe the broadcast channel
distributing events is to send a oneshot sender back to the main task
which will resubscribe from the broadcast sender and forward the
receiver back.

While this approach might seem overly complicated, it ensures there will
be no lingering receivers laying around, which in turn allows for
Arc::unwrap_or_clone to properly unwrap all messages when only one
output is in use.
This allows regular fact builds to keep using just the gRPC and stodout
outputs, no additional dependencies.
@Molter73 Molter73 force-pushed the mauro/feat/otel-output branch from adbbbd2 to 3803d50 Compare July 3, 2026 15:24
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