Add Compare metrics in Discover button to infrastructure metrics tables#273406
Merged
Conversation
updated discover link for pods to use pod.name added unit tests
jennypavlova
approved these changes
Jun 18, 2026
jennypavlova
left a comment
Member
There was a problem hiding this comment.
The Code LGTM 💯 PS. The PR labels were missing, I guess we don't need to backport, do we?
| ); | ||
| const discoverParams = { | ||
| timeRange: { from: timerange.from, to: timerange.to }, | ||
| breakdownField: getDiscoverBreakdownForNodeType(nodeType as NodeTypeForLink), |
Member
There was a problem hiding this comment.
Q: Why do we need this type cast? From what I see the nodeType should be of type NodeTypeForLink 🤔
Contributor
Author
There was a problem hiding this comment.
I initial had the nodeType prop as a string, and refactored; missed this in the refactor. Thanks for catching it!
|
Pinging @elastic/obs-presentation-team (Team:obs-presentation) |
removed unnecessary cast
Contributor
💛 Build succeeded, but was flaky
Failed CI StepsTest Failures
Metrics [docs]Module Count
Async chunks
History
|
mbondyra
added a commit
to mbondyra/kibana
that referenced
this pull request
Jun 22, 2026
…g_generation * commit '60291b6f7d78ff0d63fd22e399543fb8a444ace8': (78 commits) [Fleet] Take into account checkin jitter delay to compute offline status (elastic#274365) [ObsUX][Scout] Add global teardown + per-suite cleanup for APM/Infra/Profiling (elastic#274313) [Entity Store] Add CPS log extraction support (elastic#268007) [DOCS] Add changelogs for Jun 16 and 18 serverless releases (elastic#274217) Add Compare metrics in Discover button to infrastructure metrics tables (elastic#273406) [Content List] Migrate Graph Listing to Content List (elastic#268796) [One Workflow] Make workflow Liquid limit errors configurable (elastic#273596) Add Security data generator agent skill (elastic#274042) [Security Solution] Remove unnecessary async/act wrappers in InvestigationSection tests (elastic#274363) [User storage] improve dev docs (elastic#274073) [Security Solution] Refactor shared alert route handlers into pure operations (elastic#274228) [Flaky] Fix index.test.ts (fixes elastic#267813) (elastic#274242) Fix FIPS Pipeline - Leave OSS enabled (elastic#273776) [Alerting V2] Hide "Create with agent" button when agent builder is unavailable (elastic#274165) [ML] Remove old FTR filter lists API tests after migration to Scout (elastic#274374) [Fleet] Fix version selector not showing after uninstall when newer version is available (elastic#273929) Make profile ID available in Task Manager fake requests (elastic#261423) fix(test): logout before deleting anonymous_user to prevent afterEach timeout (elastic#274001) [Security Solution] Fix flaky install_table sort: guard against React state race in sortByTableColumn (elastic#274262) [discover-scout] Tabs FTR tests to Scout migration part 1 (elastic#272293) ... Co-authored-by: Cursor <cursoragent@cursor.com> # Conflicts: # x-pack/platform/plugins/shared/agent_builder_dashboards/server/skills/dashboard_management_skill.ts # x-pack/platform/plugins/shared/agent_builder_dashboards/server/tools/generate/core/operations/set_metadata.ts
flash1293
pushed a commit
to flash1293/kibana
that referenced
this pull request
Jun 23, 2026
…es (elastic#273406) ## Summary - Adds a **Compare metrics in Discover** action to the host, container, and pod infrastructure metrics tables in `metrics_data_access`. - Introduces `AnalyzeMetricButton` and `CompareMetricNodesLink`, which build an ES|QL time-series query filtering the visible table rows and open Discover with a breakdown field for side-by-side metric comparison. - Wires the button into all three node-type tables and exports `AnalyzeMetricButton` from the infrastructure metrics tables public surface. https://github.com/user-attachments/assets/27a12a27-18be-4e37-978d-f8a41704c230 ## Caveats Currently, this implementation only captures the ids of entities from the first page of the infrastructure table. I think that this is sufficient for the feature, and to reduce potential for URI length limitation issues. For example: the containers table in the demo video has 10 pages of results. However, other solutions are welcome.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
metrics_data_access.AnalyzeMetricButtonandCompareMetricNodesLink, which build an ES|QL time-series query filtering the visible table rows and open Discover with a breakdown field for side-by-side metric comparison.AnalyzeMetricButtonfrom the infrastructure metrics tables public surface.Screenshot.2026-06-10.at.2.52.41.PM.mov
Caveats
Currently, this implementation only captures the ids of entities from the first page of the infrastructure table. I think that this is sufficient for the feature, and to reduce potential for URI length limitation issues. For example: the containers table in the demo video has 10 pages of results. However, other solutions are welcome.