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

Telemetry uses es client provided from start contract #67279

Closed

Conversation

mshustov
Copy link
Contributor

Summary

Part of #55397
Required to get rid elasticsearch API provided from setup lifecycle.

telemetryCollectionManager.setCollection({
esCluster: core.elasticsearch.dataClient,
esCluster: core.elasticsearch.legacy.client,
Copy link
Contributor Author

@mshustov mshustov May 25, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@afharo do you know a reason why it wouldn't work if we move setCollection to the start lifecycle?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I bet there's a point in the code where we are trying to read the telemetry from the setup lifecycle step (on top of my mind

bulkUploader.start(plugins.usageCollection);
but there might be more).

I can try to dig deeper on it :)

Copy link
Contributor Author

@mshustov mshustov May 26, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

where we are trying to read the telemetry from the

Ha. Good to know, thanks! I will try to move this piece of the code in start lifecycle. That definitely shouldn't be in setup, since telemetry API might be called by other plugins during setup.

I can try to dig deeper on it :)

I will ping you if I didn't fix it with ^^^

@kibanamachine
Copy link
Contributor

💔 Build Failed

Failed CI Steps


Test Failures

Kibana Pipeline / kibana-xpack-agent / X-Pack API Integration Tests.x-pack/test/api_integration/apis/telemetry/telemetry_local·js.apis Telemetry /api/telemetry/v2/clusters/_stats with monitoring disabled should pull local stats and validate data types

Link to Jenkins

Standard Out

Failed Tests Reporter:
  - Test has failed 4 times on tracked branches: https://github.com/elastic/kibana/issues/45983

[00:00:00]       │
[00:00:00]         └-: apis
[00:00:00]           └-> "before all" hook
[00:01:39]           └-: Telemetry
[00:01:39]             └-> "before all" hook
[00:01:43]             └-: /api/telemetry/v2/clusters/_stats with monitoring disabled
[00:01:43]               └-> "before all" hook
[00:01:43]               └-> "before all" hook
[00:01:44]               └-> should pull local stats and validate data types
[00:01:44]                 └-> "before each" hook: global before each
[00:01:44]                 └- ✖ fail: "apis Telemetry /api/telemetry/v2/clusters/_stats with monitoring disabled should pull local stats and validate data types"
[00:01:44]                 │

Stack Trace

Error: expected 0 to equal 1
    at Assertion.assert (/dev/shm/workspace/kibana/packages/kbn-expect/expect.js:100:11)
    at Assertion.be.Assertion.equal (/dev/shm/workspace/kibana/packages/kbn-expect/expect.js:227:8)
    at Assertion.be (/dev/shm/workspace/kibana/packages/kbn-expect/expect.js:69:22)
    at Context.it (test/api_integration/apis/telemetry/telemetry_local.js:59:30)

Kibana Pipeline / kibana-xpack-agent / X-Pack API Integration Tests.x-pack/test/api_integration/apis/telemetry/telemetry_local·js.apis Telemetry /api/telemetry/v2/clusters/_stats with monitoring disabled should pull local stats and validate data types

Link to Jenkins

Standard Out

Failed Tests Reporter:
  - Test has failed 4 times on tracked branches: https://github.com/elastic/kibana/issues/45983

[00:00:00]       │
[00:00:00]         └-: apis
[00:00:00]           └-> "before all" hook
[00:01:39]           └-: Telemetry
[00:01:39]             └-> "before all" hook
[00:01:43]             └-: /api/telemetry/v2/clusters/_stats with monitoring disabled
[00:01:43]               └-> "before all" hook
[00:01:43]               └-> "before all" hook
[00:01:44]               └-> should pull local stats and validate data types
[00:01:44]                 └-> "before each" hook: global before each
[00:01:44]                 └- ✖ fail: "apis Telemetry /api/telemetry/v2/clusters/_stats with monitoring disabled should pull local stats and validate data types"
[00:01:44]                 │

Stack Trace

Error: expected 0 to equal 1
    at Assertion.assert (/dev/shm/workspace/kibana/packages/kbn-expect/expect.js:100:11)
    at Assertion.be.Assertion.equal (/dev/shm/workspace/kibana/packages/kbn-expect/expect.js:227:8)
    at Assertion.be (/dev/shm/workspace/kibana/packages/kbn-expect/expect.js:69:22)
    at Context.it (test/api_integration/apis/telemetry/telemetry_local.js:59:30)

History

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

@mshustov mshustov closed this May 28, 2020
@mshustov mshustov deleted the telemetry-uses-es-from-start branch May 28, 2020 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore release_note:skip Skip the PR/issue when compiling release notes v7.9.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants