Skip to content
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

[APM] Many environments are not displayed in dropdown filter #77695

Closed
ogupte opened this issue Sep 17, 2020 · 5 comments · Fixed by #82090
Closed

[APM] Many environments are not displayed in dropdown filter #77695

ogupte opened this issue Sep 17, 2020 · 5 comments · Fixed by #82090
Assignees
Labels
bug Fixes for quality problems that affect the customer experience Team:APM All issues that need APM UI Team support

Comments

@ogupte
Copy link
Contributor

ogupte commented Sep 17, 2020

When exploring an instance with a lot of environments, not all environments will display in the environment filter. This might be because we query for environments using a terms agg with a size specified (https://github.com/elastic/kibana/blob/master/x-pack/plugins/apm/server/lib/ui_filters/get_environments.ts#L56-L59). The solution might be more involved than specifying a large enough size because a large size would greatly impact performance. Another solution would be to use a composite aggregration to get the distinct environment values. This would introduce pagination to this query which might need changes to the UI selector to trigger loading new page of environments.

Screen Shot 2020-09-16 at 5.34.12 PM.png

Related: #77573

@ogupte ogupte added [zube]: Inbox bug Fixes for quality problems that affect the customer experience Team:APM All issues that need APM UI Team support labels Sep 17, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/apm-ui (Team:apm)

@henrikno
Copy link
Contributor

Just noticed it stops at 10 (including Not defined), the default size for aggregations, so this is likely the cause.

@alex-fedotyev
Copy link

It looks like fixing the query would be important here.

@ogupte - would it make sense to redesign the environment selector and make it a dropdown with a typeahead for better usability?
35449032-df1deda4-0289-11e8-9048-3667d562a83a

@sorenlouv
Copy link
Member

sorenlouv commented Sep 18, 2020

I don't think we've seen customers with 100s of environments (they are often less than 10), so I'm not sure if this is a scenario we should invest in improving.
If we add support for spaces would that alleviate the problem?

For the time being, instead of registering a separate environment per dev, could they set a separate service name? I know it seems like a hack but would probably work better.

@nehaduggal
Copy link

@sqren don't think adding support for spaces would exactly solve the issue and creating service names with environments is pretty hacky(also won't work for things like maps where you want to view maps of specific environments only). Lets make the query configurable for now to unblock folks and consider re-designing the filter as per @alex-fedotyev suggestion?

@ogupte ogupte self-assigned this Oct 29, 2020
ogupte added a commit to ogupte/kibana that referenced this issue Oct 29, 2020
Adds new configuration 'xpack.apm.ui.maxServiceEnvironments' to set the
max number of service environments visible in APM UI.
ogupte added a commit that referenced this issue Nov 6, 2020
* Closes #77695.
Adds new configuration 'xpack.apm.ui.maxServiceEnvironments' to set the
max number of service environments visible in APM UI.

* renamed config 'xpack.apm.ui.maxServiceEnvironments' -> 'xpack.apm.maxServiceEnvironments'

* Renames 'xpack.apm.ui.maxServiceEnvironments' -> 'xpack.apm.maxServiceEnvironments' in the docs.

* removed incorrect size param on the composite terms sub-agg

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
ogupte added a commit to ogupte/kibana that referenced this issue Nov 6, 2020
…tic#82090)

* Closes elastic#77695.
Adds new configuration 'xpack.apm.ui.maxServiceEnvironments' to set the
max number of service environments visible in APM UI.

* renamed config 'xpack.apm.ui.maxServiceEnvironments' -> 'xpack.apm.maxServiceEnvironments'

* Renames 'xpack.apm.ui.maxServiceEnvironments' -> 'xpack.apm.maxServiceEnvironments' in the docs.

* removed incorrect size param on the composite terms sub-agg

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
ogupte added a commit that referenced this issue Nov 10, 2020
…) (#82903)

* Closes #77695.
Adds new configuration 'xpack.apm.ui.maxServiceEnvironments' to set the
max number of service environments visible in APM UI.

* renamed config 'xpack.apm.ui.maxServiceEnvironments' -> 'xpack.apm.maxServiceEnvironments'

* Renames 'xpack.apm.ui.maxServiceEnvironments' -> 'xpack.apm.maxServiceEnvironments' in the docs.

* removed incorrect size param on the composite terms sub-agg

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience Team:APM All issues that need APM UI Team support
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants