-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add 'pipeline' attribute to processor metrics #11171
Add 'pipeline' attribute to processor metrics #11171
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #11171 +/- ##
==========================================
- Coverage 91.47% 91.40% -0.08%
==========================================
Files 424 424
Lines 20206 20207 +1
==========================================
- Hits 18484 18470 -14
- Misses 1339 1354 +15
Partials 383 383 ☔ View full report in Codecov by Sentry. |
16e2224
to
fef38a3
Compare
f9d4226
to
9bece81
Compare
One notable detail is that the |
856197e
to
0278ec4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The approach looks reasonable to me. There are some breaking changes on the test modules, I feel like those are okay (and that maybe we should split that part of the modules off to make our lives easier, but that's for another PR)
77300d1
to
b1bf422
Compare
I added a changelog to note to breaking change in |
I opened #11179 to capture thoughts on the broader question of which attributes to apply to each kind of component. This PR aligns with what I believe is the best overall schema, but please take a look. |
8efa7be
to
496326f
Compare
@@ -20,11 +20,12 @@ import ( | |||
var nopType = component.MustNewType("nop") | |||
|
|||
// NewNopSettings returns a new nop settings for Create*Processor functions. | |||
func NewNopSettings() processor.Settings { | |||
func NewNopSettings(dt component.DataType) processor.Settings { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any thoughts on whether we should require this argument for other test packages, just for consistency? The situation I am worried about is that we eventually want to pass the pipeline ID for some reason (not necessarily self telemetry) for all components and we end up having to change it everywhere
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems likely we'll want to include the data type for other component kinds. I suppose we could pass the pipeline ID here for processors, but not sure there's any case to do it for other kinds. This is probably something worth trying to iron out as part of #11179.
b8ddb2a
to
d47db79
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this already done?
processor/internal/processor.go
Outdated
// PipelineID indicates which pipeline contains this processor. | ||
PipelineID pipeline.ID |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Settings are passed to the factory method correct? Which already signals which "signal" is this for. I am confused why adding it here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This indicates the pipeline ID, not the signal. The rationale for adding pipeline ID is explained in #10908
d47db79
to
23d20f7
Compare
Please rebase, looks like everything changed since this change was made. |
I'm closing this in favor of the graph based approach, demonstrated in #11311 (review) and more robustly proposed in #11343. |
Resolves #10908
This ends up being a pretty straightforward change in actual code, but a tedious change in tests. It's also obviously a breaking change for anyone depending on these metrics.