-
Notifications
You must be signed in to change notification settings - Fork 2.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
Feat: expand kafka broker metrics #24259
Conversation
feat: update kafka connect for NR
|
@dmitryax , I didn't have a way to update the other PR since I did not raise it, so unfortunately I had to create a new one. I did however rebase with main and run For the question that was posed in the previous PR - |
Ok, but this is not a New Relic specific component. Sums are usually preferable in OpenTelemetry because they are more resilient to data points misses. You can use https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/processor/cumulativetodeltaprocessor to translate all the cumulative metrics to deltas. Also, please take a look at metrics already defined in the Semantic Conventions https://github.com/open-telemetry/semantic-conventions/blob/ca881074f6df330bacdaa89372f2851c26545fee/docs/messaging/kafka.md?plain=1#L104C13-L104C29. |
Got it. I'm just catching up on this integration, but I'm thinking that For the second point, changing the name to |
Yes, the metric currently defined in the spec |
There is a PR to semantic conventions originally submitted with this change open-telemetry/semantic-conventions#113. I added a couple of comments, and hopefully we will get more attention from approvers/maintainers of that project |
understood, I may have to resubmit that one as well because I don't have privileges on that fork. I see your comments though, I'll make those changes and hopefully make that easy for approvers. Just so I'm clear, what is the order of approval on both of these? Do I need to get that one approved prior to this one or the other way around? |
Ideally, yes. Otherwise, metrics submitted here are more likely to be changed later. But feel free to work on both in parallel. This PR has some CI failures that should be fixed. We also need to start adding them to the new |
@dmitryax I had the same issue with other PR, I didn't have access to make changes to that fork so I had to create a new one. I did review your suggestions and I made the requested changes though, so hopefully this new one is in a more ready state. |
@dmitryax commenting back on this one. I saw the request to run |
You don't have |
I do have it installed. It starts to run but it gives an error on doc.go:5: running "mdatagen": exec: "mdatagen": executable file not found in $PATH |
Please try |
Sorry for the delay on this one. I could not get the test to run locally, so I had to run it in EC2, hence all the commits. I added the broker metrics to the integration test, and it passes when I run it, and I verified that the metrics are being collected as well by running the collector with everything enabled. The only thing I'm missing is writing to the expected.yaml, for some reason it keeps writing a blank object, but it is working so I don't know why it's doing that. |
@dmitryax , let me know if this works. I added the metrics to the test, and I also tested the collector to make sure they were coming. |
// scraperinttest.WriteExpected(), // TODO remove | ||
scraperinttest.WithCompareOptions( | ||
// pmetrictest.IgnoreMetricValues(), | ||
pmetrictest.IgnoreStartTimestamp(), | ||
pmetrictest.IgnoreTimestamp(), | ||
), | ||
scraperinttest.WriteExpected(), |
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.
Please remove this. This line is intender to be executed once locally to produce the expected.yaml
file
rCfg.Metrics.KafkaConsumerGroupLag.Enabled = true | ||
rCfg.Metrics.KafkaConsumerGroupLagSum.Enabled = true | ||
rCfg.Metrics.KafkaConsumerGroupMembers.Enabled = true | ||
rCfg.Metrics.KafkaConsumerGroupOffset.Enabled = true | ||
rCfg.Metrics.KafkaConsumerGroupOffsetSum.Enabled = true | ||
rCfg.Metrics.KafkaPartitionCurrentOffset.Enabled = true | ||
rCfg.Metrics.KafkaPartitionOldestOffset.Enabled = true | ||
rCfg.Metrics.KafkaPartitionReplicas.Enabled = true | ||
rCfg.Metrics.KafkaPartitionReplicasInSync.Enabled = true | ||
rCfg.Metrics.KafkaTopicPartitions.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerConsumerFetchCount.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerConsumerFetchRate.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerCount.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerIncomingByteRate.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerOutgoingByteRate.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerRequestLatency.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerRequestRate.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerRequestSize.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerRequestsInFlight.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerResponseRate.Enabled = true | ||
rCfg.Metrics.MessagingKafkaBrokerResponseSize.Enabled = true |
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.
We have all the metrics enabled, but the expected.yaml
output doesn't have anything new. It means the integration test doesn't work some reason
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.
Hmm, I never got it to write anything to expected.yaml, but I was getting metrics from it when I ran the collector. That does seem to indicate it's an issue in the integration test, but the only thing I've changed here is just enabling the metrics.
This PR was marked stale due to lack of activity. It will be closed in 14 days. |
Closed as inactive. Feel free to reopen if this PR is still being worked on. |
Rebasing and resubmitting from the original PR due to new team ownership.
ORIGINAL PR: 23646