Skip to content

[8.7] [Fleet] Fix EPR and custom integration categories merge (#153221)#153225

Merged
kibanamachine merged 1 commit intoelastic:8.7from
kibanamachine:backport/8.7/pr-153221
Mar 15, 2023
Merged

[8.7] [Fleet] Fix EPR and custom integration categories merge (#153221)#153225
kibanamachine merged 1 commit intoelastic:8.7from
kibanamachine:backport/8.7/pr-153221

Conversation

@kibanamachine
Copy link
Copy Markdown
Contributor

Backport

This will backport the following commits from main to 8.7:

Questions ?

Please refer to the Backport tool documentation

## Summary

While testing elastic/integrations#5123 and
elastic#153216, I discovered two problems
with the list of categories on the Browse integration page:

1. The categories list doesn't respect `showIntegrationsSubcategories`
feature flag. When it is turned off, it will still only display
top-level parent categories. This PR fixes that so that when
`showIntegrationsSubcategories` is turned off, _all_ categories will be
listed on the left sidebar. When it is turned on, only the top-level
categories will be listed.
2. The merging of the categories list from EPR (i.e.
`<EPR_HOST>/categories`) with the categories hard-coded in Kibana for
custom integration cards is flawed: there can be a situation where a
category or subcategory is not returned by EPR, due to no EPR-hosted
integrations having it, but it is registered by a custom card. In this
case, the category is missing from the list. This PR fixes the merging
logic.

(cherry picked from commit 340ee10)
@kibanamachine kibanamachine added the backport This PR is a backport of another PR label Mar 15, 2023
@kibanamachine kibanamachine enabled auto-merge (squash) March 15, 2023 15:59
@botelastic botelastic bot added the Team:Fleet Team label for Observability Data Collection Fleet team label Mar 15, 2023
@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/fleet (Team:Fleet)

@kibana-ci
Copy link
Copy Markdown

💚 Build Succeeded

Metrics [docs]

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
customIntegrations 88 156 +68

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
fleet 930.0KB 930.1KB +104.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
customIntegrations 7.4KB 8.2KB +850.0B
Unknown metric groups

API count

id before after diff
customIntegrations 107 175 +68

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @jen-huang

@kibanamachine kibanamachine merged commit f9854bb into elastic:8.7 Mar 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport This PR is a backport of another PR Team:Fleet Team label for Observability Data Collection Fleet team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants