-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[Stack Monitoring] Additional APM metrics #43998
Conversation
pulling in @elastic/apm-server for visibility |
@chrisronline OK, this passed tests for me locally so it's probably ready for a first pass from you. Thanks! |
💔 Build Failed |
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 looks GREAT so far! Awesome work!
I made a couple of small notes, but I don't see any major issues!
We should probably add/adjust existing tests to account for this, but I imagine you'll do that while getting CI passing. I'll wait to do a final review until then.
x-pack/legacy/plugins/monitoring/server/lib/metrics/apm/metrics.js
Outdated
Show resolved
Hide resolved
x-pack/legacy/plugins/monitoring/server/lib/metrics/apm/metrics.js
Outdated
Show resolved
Hide resolved
💔 Build Failed |
💔 Build Failed |
💔 Build Failed |
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.
Thanks for getting this in that quickly. I left a couple of comments.
x-pack/legacy/plugins/monitoring/server/lib/metrics/__test__/__snapshots__/metrics.test.js.snap
Show resolved
Hide resolved
x-pack/legacy/plugins/monitoring/server/lib/metrics/__test__/__snapshots__/metrics.test.js.snap
Outdated
Show resolved
Hide resolved
x-pack/legacy/plugins/monitoring/server/lib/metrics/__test__/__snapshots__/metrics.test.js.snap
Outdated
Show resolved
Hide resolved
x-pack/legacy/plugins/monitoring/server/lib/metrics/__test__/__snapshots__/metrics.test.js.snap
Outdated
Show resolved
Hide resolved
x-pack/legacy/plugins/monitoring/server/lib/metrics/__test__/__snapshots__/metrics.test.js.snap
Outdated
Show resolved
Hide resolved
x-pack/legacy/plugins/monitoring/server/lib/metrics/__test__/__snapshots__/metrics.test.js.snap
Outdated
Show resolved
Hide resolved
x-pack/legacy/plugins/monitoring/server/lib/metrics/apm/metrics.js
Outdated
Show resolved
Hide resolved
x-pack/legacy/plugins/monitoring/server/lib/metrics/apm/metrics.js
Outdated
Show resolved
Hide resolved
x-pack/legacy/plugins/monitoring/server/lib/metrics/apm/metrics.js
Outdated
Show resolved
Hide resolved
x-pack/legacy/plugins/monitoring/server/routes/api/v1/apm/metric_set_overview.js
Outdated
Show resolved
Hide resolved
I've discovered a potential issue. When the changes were made in elastic/apm-server#2142, there wasn't any change made to the templates which describe how the new fields should be indexed. Here is the current Elasticsearch template which is applied to the Beats monitoring index when it is created: Note that the top-level keys in However, as discussed in #44001, there is now a new top-level key for To move forward on this, I think we'd need to update the mapping first to support these new fields. That's going to involve, at a minimum, getting the Elasticsearch team (and @jakelandis) involved. However, getting this done before a FF tomorrow seems very sketchy. So, this puts us in a bit of a spot. The ES team might be willing to consider this a bug and let us get it in after the feature-freeze. However, the feature on the Kibana side (i.e., this PR) can't go in until the mapping is updated, because it will fail tests. (We could probably work around this but, again, it gets a little sketchy.) I am going to keep looking at this but wanted to get these notes down for everybody to see and discuss. @simitt My gut feeling here is that we are going to have to defer these changes for a later release. What's the impact on your side if we do so? It seems like the only issue may be potential discrepency between versions with the |
Good catch @cachedout . Unfortunately I wasn't aware of that template. There are three new top level keys for Since the values for the counters will not change, and are only created from within the APM Server, I don't think that creating the metrics will cause any issues like mapping errors. IMO the change in the APM Server can therefore be released with the next version as planned. Regarding the monitoring UI, I agree that this sounds like a too short notice. Would it be feasible to not show the ACM counters for now, but still change the titles for the existing visualizations to make it clear that they only represent values for the Intake API endpoint? |
I think that is a very wise course of action. Let's do that. I'll start on a new PR now which just makes changes to the titles. |
@cachedout I think adding the new mappings to the template is pretty straight-forward and shouldn't take long to code up and review. Here is an example of me doing this for APM in the past: elastic/elasticsearch#34392 It usually doesn't even require an Elasticsearch team member to review (so we don't have to worry about their time) |
💔 Build Failed |
@chrisronline Thanks for the link! You are right that this shouldn't be too bad. I assumed that ES folks would need to be involved so I am glad that is not the case. After going over this with @simitt it seems like we can get #44091 in and then not be so rushed with these changes, which makes me feel a little better tbh. If we have the option to be more methodical with these changes, I think we should take it. WDYT? |
Sounds good to me! |
Tests will not pass on this until elastic/elasticsearch#46244 is merged. |
💔 Build Failed |
410d4ed
to
f5f3d2c
Compare
f5f3d2c
to
eefda39
Compare
Kind of a horrific rebase but I think I got all the relevant bits back in the right place. Let's see what the tests think. :) It would be nice to get this merged. |
@elasticmachine merge upstream |
💔 Build FailedHistory
To update your PR or re-run it, just comment with: |
@chrisronline and @simitt This has been hanging around for a while. Is this still needed? If so, I can fix up the merge conflicts and let somebody take a swing at a review but since switching teams I probably don't have much time to put a lot of additional work in. Let me know what you think. Thanks! |
@cachedout it would still be nice to have the additional metrics visualized. As a matter of fact we put in even more metrics with new features. |
@chrisronline I'll defer to you here on what you would like to do. Would you like me to fix the merge conflicts and hand this over to you? Just let me know how you'd like to transfer this work over. :) Thanks! |
Can someone update the labels for this PR please? It's definitely not going out in 7.7.0 and we're past FF for 7.8.0 (and this is an enhancement), so probably 7.9.0 now. |
I believe this was superceded by #69052 |
Summary
Adds new graphs to APM.
Checklist
Use
strikethroughsto remove checklist items you don't feel are applicable to this PR.For maintainers
Testing
To test this, you need to bring up APM server and configure it to send metrics to Stack Monitoring.
Important: I have tested this with Metricbeat as well but would still appreciate a second set of eyes on all of these tests with Metricbeat in addition to native monitoring.
For all metrics described below, check to ensure that they are present and populated on both the APM overview page in Stack Monitoring as well as in any APM instance page(s).
For each metric described in #44001, verify that it is present.