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

We should have a dedicated endpoint for telemetry #58198

Open
jasontedor opened this issue Jun 16, 2020 · 5 comments
Open

We should have a dedicated endpoint for telemetry #58198

jasontedor opened this issue Jun 16, 2020 · 5 comments
Labels
:Core/Infra/Core Core issues without another label >enhancement Team:Core/Infra Meta label for core/infra team

Comments

@jasontedor
Copy link
Member

Today telemetry is collected from a variety of endpoints:

  • cluster stats /_cluster/stats
  • cluster info /
  • X-Pack usage /_xpack/usage
  • license info /_license

There are two problems with this approach:

  • first, it's unclear to our users what information is used for telemetry
  • secondly, it's unclear internally that these endpoints are for telemetry, which means from time to time we consider making changes to these endpoints that would either remove information that is useful from a telemetry perspective, or would add information that would not be useful from a telemetry perspective

If we had a single dedicated endpoint that exposed telemetry information, it would clear up some of the confusion around this, and simplify the implementation within Kibana.

There are open questions around how we expose telemetry from X-Pack in a single endpoint that would be defined in core, but @rjernst has some ideas around this that sound promising here.

Relates #52975

@jasontedor jasontedor added >enhancement :Core/Infra/Core Core issues without another label needs:triage Requires assignment of a team area label labels Jun 16, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra (:Core/Infra/Core)

@elasticmachine elasticmachine added the Team:Core/Infra Meta label for core/infra team label Jun 16, 2020
@gwbrown gwbrown removed the needs:triage Requires assignment of a team area label label Jul 6, 2020
@rjernst rjernst added the needs:triage Requires assignment of a team area label label Dec 3, 2020
@pgomulka pgomulka removed the needs:triage Requires assignment of a team area label label Dec 10, 2020
@afharo
Copy link
Member

afharo commented Feb 9, 2021

Hi! I wanted to reach out to y'all to know your thoughts about this: we are about to merge this PR in Kibana: elastic/kibana#90273

It defines the full schema (aka contract) that we send to the Remote Telemetry service. Since it includes data that we pass through from the endpoints listed in the description, if ES returns new keys in the future, Kibana CI tests will fail, and we'll need to manually add the new fields to the schema definitions in the following files:

  • OSS: src/plugins/telemetry/schema/oss_root.json
  • X-Pack: x-pack/plugins/telemetry_collection_xpack/schema/xpack_root.json

Once the dedicated telemetry endpoint is created, we'll rework this to be more automated.

What do you think?

@dakrone
Copy link
Member

dakrone commented Feb 11, 2021

I ran into an issue with the way our current telemetry works related to the /_cluster/stats endpoint. The endpoint can calculate some very expensive stats (mapping and analysis stats), which is fine for occasional telemetry retrieval, but the same endpoint is used within monitoring. In this particular case it was causing a non-negligible amount of load on the master node due to calculating the unneeded expensive stats.

Having a separate telemetry endpoint would allow these expensive-to-calculate parts that are not needed for monitoring to live in a dedicated place and avoid the load when performing monitoring.

@rjernst
Copy link
Member

rjernst commented Feb 21, 2021

@afharo Core/Infra discussed the Kibana PR mentioned. While we understand the desire and need to have a set schema, we think the schema for Elasticsearch should live in Elasticsearch, not in Kibana. Cross repo changes like proposed are very difficult from many perspectives (temporary CI breakages, awareness of need for changes, unintentional refactorings, etc). Additionally, the APIs currently hit by Kibana for telemetry are strongly outside the scope of stable APIs; this is why this dedicated endpoint issue exists. We are happy to revisit priority of the dedicated endpoint, but do not feel the proposed PR should be merged.

@afharo
Copy link
Member

afharo commented Feb 22, 2021

@rjernst I understand the concerns for the cross-repo dependency. I totally agree with the risks. IMO, the fact that Kibana is reporting telemetry on behalf of Elasticsearch is already a cross-product dependency on its own.

I'd like to CC the telemetry stakeholders so we manage the expectations and prioritisations: @alexfrancoeur @thesmallestduck @elastic/infra-telemetry

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Core/Infra/Core Core issues without another label >enhancement Team:Core/Infra Meta label for core/infra team
Projects
None yet
Development

No branches or pull requests

7 participants