Skip to content

feat: add network.type as attribute for network flows - #887

Merged
grcevski merged 1 commit into
open-telemetry:mainfrom
theSuess:feat/network-type-attribute
Nov 12, 2025
Merged

feat: add network.type as attribute for network flows#887
grcevski merged 1 commit into
open-telemetry:mainfrom
theSuess:feat/network-type-attribute

Conversation

@theSuess

Copy link
Copy Markdown
Contributor

This adds support for the network.type attribute as specified in the OTEL Semantic
Conventions
. It follows a similar approach to the transport attribute and can be extended to support more protocols easily

Adding this field allows for easier aggregation without resorting to checking for : in the address fields

@theSuess
theSuess requested a review from a team as a code owner November 12, 2025 13:03

@grcevski grcevski 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.

LGTM! Nice!

Comment thread pkg/export/attributes/attr_defs.go
@codecov

codecov Bot commented Nov 12, 2025

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 38.88889% with 11 lines in your changes missing coverage. Please review.
✅ Project coverage is 55.08%. Comparing base (98cc6aa) to head (846bc9c).
⚠️ Report is 4 commits behind head on main.

Files with missing lines Patch % Lines
pkg/internal/netolly/flow/transport/networktype.go 21.42% 11 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #887   +/-   ##
=======================================
  Coverage   55.08%   55.08%           
=======================================
  Files         251      252    +1     
  Lines       21505    21523   +18     
=======================================
+ Hits        11845    11856   +11     
- Misses       8843     8852    +9     
+ Partials      817      815    -2     
Flag Coverage Δ
integration-test 23.26% <5.55%> (-0.05%) ⬇️
integration-test-arm 0.00% <0.00%> (ø)
integration-test-vm-${ARCH}-${KERNEL_VERSION} 0.00% <0.00%> (?)
k8s-integration-test 2.75% <0.00%> (-0.01%) ⬇️
oats-test 0.00% <0.00%> (ø)
unittests 46.21% <38.88%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 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.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@theSuess
theSuess force-pushed the feat/network-type-attribute branch from 3896f22 to eeac45f Compare November 12, 2025 14:38
This adds support for the `network.type` attribute as specified in the OTEL
[Semantic
Conventions](https://opentelemetry.io/docs/specs/semconv/registry/attributes/network/#network-type).
It follows a similar approach to the `transport` attribute and can be extended
to support more protocols easily
@theSuess
theSuess force-pushed the feat/network-type-attribute branch from eeac45f to 846bc9c Compare November 12, 2025 14:39
@theSuess
theSuess requested a review from grcevski November 12, 2025 16:06
Comment thread pkg/export/attributes/attr_defs.go
@grcevski
grcevski merged commit 3daf08d into open-telemetry:main Nov 12, 2025
50 checks passed
@grcevski

Copy link
Copy Markdown
Contributor

Thanks for your contribution @theSuess !

@MrAlias MrAlias added this to the v0.3.0 milestone Dec 3, 2025
@MrAlias MrAlias mentioned this pull request Dec 3, 2025
marctc pushed a commit to grafana/opentelemetry-ebpf-instrumentation that referenced this pull request Dec 9, 2025
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