-
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
[Inventory][ECO] Use ControlGroupRenderer to filter by entity types #199174
[Inventory][ECO] Use ControlGroupRenderer to filter by entity types #199174
Conversation
x-pack/plugins/observability_solution/inventory/e2e/cypress/e2e/home.cy.ts
Outdated
Show resolved
Hide resolved
🤖 GitHub commentsExpand to view the GitHub comments
Just comment with:
|
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.
x-pack/plugins/observability_solution/inventory/public/components/app_root/index.tsx
Show resolved
Hide resolved
...ck/plugins/observability_solution/inventory/public/components/search_bar/discover_button.tsx
Outdated
Show resolved
Hide resolved
x-pack/plugins/observability_solution/inventory/public/hooks/use_kibana_query_settings.ts
Outdated
Show resolved
Hide resolved
public reportEntityInventoryEntityTypeFiltered = ( | ||
params: EntityInventoryEntityTypeFilteredParams | ||
) => { | ||
this.analytics.reportEvent(TelemetryEventTypes.ENTITY_INVENTORY_ENTITY_TYPE_FILTERED, params); | ||
}; | ||
|
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 don't need this telemetry info anymore?
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's no longer as straightforward as it was before to get the selected entity types now using control groups. The selected items are in the URL anyway.
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.
Got it. should we align this with Roshan?
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.
cc: @roshan-elastic
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.
Hey @cauemarcondes @crespocarlos - will we still be able to populate the telemetry like this?
{
"timestamp": "2024-11-12T11:20:08.790Z",
"event_type": "Entity Inventory Search Query Submitted",
"context": {
...
},
"properties": {
"kuery_fields": ["entity.name"],
"entity_types": ["service"],
"action": "refresh"
}
}
Not super fussed if we explicitly track the control filter itself but if someone filters by entity.type
either via the control filter via a query - we need to track this.
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.
No, we won't be able to. The control group has a complex data structure and it's not possible to easily extract the selected options. It also can select item but exclude them from the query.
x-pack/plugins/observability_solution/inventory/public/hooks/use_unified_search_url.ts
Outdated
Show resolved
Hide resolved
x-pack/plugins/observability_solution/inventory/public/hooks/use_unified_search_url.ts
Show resolved
Hide resolved
x-pack/plugins/observability_solution/inventory/public/components/search_bar/index.tsx
Show resolved
Hide resolved
x-pack/plugins/observability_solution/inventory/e2e/cypress/e2e/home.cy.ts
Outdated
Show resolved
Hide resolved
x-pack/plugins/observability_solution/inventory/public/components/search_bar/index.tsx
Outdated
Show resolved
Hide resolved
x-pack/plugins/observability_solution/inventory/public/hooks/use_discover_redirect.ts
Outdated
Show resolved
Hide resolved
x-pack/plugins/observability_solution/inventory/public/hooks/use_discover_redirect.ts
Outdated
Show resolved
Hide resolved
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.
LGTM 🚀 Thanks for the changes!
💚 Build Succeeded
Metrics [docs]Module Count
Public APIs missing comments
Async chunks
Page load bundle
Unknown metric groupsAPI count
ESLint disabled line counts
Total ESLint disabled count
History
|
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.
Logs UI changes LGTM
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.
LGTM! I would just double check with Roshan the removal of the telemetry event. We could also open a follow up PR to add it back, if we need to.
@@ -119,7 +119,7 @@ pageLoadAssetSize: | |||
observabilityAiAssistantManagement: 19279 | |||
observabilityLogsExplorer: 46650 | |||
observabilityOnboarding: 19573 | |||
observabilityShared: 80000 | |||
observabilityShared: 111036 |
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.
I wonder if there is anything we could do to avoid increasing the plugin size 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.
Yeah, I was thinking about this too. But this is out of the scope of this PR. I think this is a good topic for the Devex-ui-wg
.
Starting backport for target branches: 8.x |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation |
…lastic#199174) closes elastic#193397 https://github.com/user-attachments/assets/e78639a8-bc63-4c5a-8676-0ad9b5f0563e - Added `Entity type` control group field on the Inventory page. - Added `Filters` buttons to the Unified Search bar on the Inventory oage - Moved common hooks from infra to Obs-shared - Refactoring --------- Co-authored-by: kibanamachine <[email protected]> (cherry picked from commit 4a16e91)
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…lastic#199174) closes elastic#193397 https://github.com/user-attachments/assets/e78639a8-bc63-4c5a-8676-0ad9b5f0563e - Added `Entity type` control group field on the Inventory page. - Added `Filters` buttons to the Unified Search bar on the Inventory oage - Moved common hooks from infra to Obs-shared - Refactoring --------- Co-authored-by: kibanamachine <[email protected]>
…ypes (#199174) (#199820) # Backport This will backport the following commits from `main` to `8.x`: - [[Inventory][ECO] Use ControlGroupRenderer to filter by entity types (#199174)](#199174) <!--- Backport version: 8.9.8 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Cauê Marcondes","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-11-12T10:28:02Z","message":"[Inventory][ECO] Use ControlGroupRenderer to filter by entity types (#199174)\n\ncloses https://github.com/elastic/kibana/issues/193397\r\n\r\n\r\nhttps://github.com/user-attachments/assets/e78639a8-bc63-4c5a-8676-0ad9b5f0563e\r\n\r\n- Added `Entity type` control group field on the Inventory page. \r\n- Added `Filters` buttons to the Unified Search bar on the Inventory\r\noage\r\n- Moved common hooks from infra to Obs-shared\r\n- Refactoring\r\n\r\n---------\r\n\r\nCo-authored-by: kibanamachine <[email protected]>","sha":"4a16e910e95d62fd4cc52f4a870147d691b1a681","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","backport:prev-minor","ci:project-deploy-observability","v8.17.0"],"number":199174,"url":"https://github.com/elastic/kibana/pull/199174","mergeCommit":{"message":"[Inventory][ECO] Use ControlGroupRenderer to filter by entity types (#199174)\n\ncloses https://github.com/elastic/kibana/issues/193397\r\n\r\n\r\nhttps://github.com/user-attachments/assets/e78639a8-bc63-4c5a-8676-0ad9b5f0563e\r\n\r\n- Added `Entity type` control group field on the Inventory page. \r\n- Added `Filters` buttons to the Unified Search bar on the Inventory\r\noage\r\n- Moved common hooks from infra to Obs-shared\r\n- Refactoring\r\n\r\n---------\r\n\r\nCo-authored-by: kibanamachine <[email protected]>","sha":"4a16e910e95d62fd4cc52f4a870147d691b1a681"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","labelRegex":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/199174","number":199174,"mergeCommit":{"message":"[Inventory][ECO] Use ControlGroupRenderer to filter by entity types (#199174)\n\ncloses https://github.com/elastic/kibana/issues/193397\r\n\r\n\r\nhttps://github.com/user-attachments/assets/e78639a8-bc63-4c5a-8676-0ad9b5f0563e\r\n\r\n- Added `Entity type` control group field on the Inventory page. \r\n- Added `Filters` buttons to the Unified Search bar on the Inventory\r\noage\r\n- Moved common hooks from infra to Obs-shared\r\n- Refactoring\r\n\r\n---------\r\n\r\nCo-authored-by: kibanamachine <[email protected]>","sha":"4a16e910e95d62fd4cc52f4a870147d691b1a681"}},{"branch":"8.x","label":"v8.17.0","labelRegex":"^v8.17.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT-->
…lastic#199174) closes elastic#193397 https://github.com/user-attachments/assets/e78639a8-bc63-4c5a-8676-0ad9b5f0563e - Added `Entity type` control group field on the Inventory page. - Added `Filters` buttons to the Unified Search bar on the Inventory oage - Moved common hooks from infra to Obs-shared - Refactoring --------- Co-authored-by: kibanamachine <[email protected]>
closes #193397
control.groups.mov
Entity type
control group field on the Inventory page.Filters
buttons to the Unified Search bar on the Inventory oage