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

[Stack Monitoring] implement baseline elasticsearch api tests for package and metricbeat data #149161

Merged
merged 20 commits into from
Jan 30, 2023

Conversation

klacabane
Copy link
Contributor

@klacabane klacabane commented Jan 18, 2023

Summary

Part of #148303
Closes #146067
Closes #146068

I investigated the failing tests but couldn't get to the root cause quickly enough so I took the opportunity to port the tests to the monitoring_api_integration suite. This reimplements all the existing tests (plus missing ones for the ml_jobs api) with fresh data.
By using the new testing approach we can remove the archived mappings which greatly reduce execution times.

Testing

  • The suite was executed against by the flaky test runner multiple times with no failures
  • Test data is bundled in two archives (one for metricbeat and one for package data) and can be loaded to verify their content: node scripts/es_archiver.js load x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node/(package|metricbeat) --es-url=http://elastic:changeme@localhost:9200 --kibana-url=http://elastic:changeme@localhost:5601

@klacabane klacabane changed the title enable flaky test [Stack Monitoring] implement baseline elasticsearch api tests for package and metricbeat data Jan 26, 2023
@klacabane klacabane self-assigned this Jan 27, 2023
@klacabane klacabane added Team:Infra Monitoring UI - DEPRECATED DEPRECATED - Label for the Infra Monitoring UI team. Use Team:obs-ux-infra_services release_note:skip Skip the PR/issue when compiling release notes Feature:Stack Monitoring labels Jan 27, 2023
@klacabane klacabane marked this pull request as ready for review January 27, 2023 10:36
@klacabane klacabane requested a review from a team as a code owner January 27, 2023 10:36
@elasticmachine
Copy link
Contributor

Pinging @elastic/infra-monitoring-ui (Team:Infra Monitoring UI)

@crespocarlos
Copy link
Contributor

@elasticmachine merge upstream

Copy link
Contributor

@crespocarlos crespocarlos left a comment

Choose a reason for hiding this comment

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

LGTM! Good to see that we now use just 2 archives, instead of one per test case. I've run some tests against a cloud environment and everything works fine.

@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

✅ unchanged

History

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

cc @klacabane

@klacabane klacabane merged commit d9adcca into elastic:main Jan 30, 2023
@kibanamachine kibanamachine added v8.7.0 backport:skip This commit does not require backporting labels Jan 30, 2023
kqualters-elastic pushed a commit to kqualters-elastic/kibana that referenced this pull request Feb 6, 2023
…kage and metricbeat data (elastic#149161)

### Summary

Part of elastic#148303
Closes elastic#146067
Closes elastic#146068

I investigated the failing tests but couldn't get to the root cause
quickly enough so I took the opportunity to port the tests to the
[monitoring_api_integration](https://github.com/elastic/kibana/tree/main/x-pack/test/monitoring_api_integration)
suite. This reimplements all the existing tests (plus missing ones for
the `ml_jobs` api) with fresh data.
By using the new testing approach we can remove the archived mappings
which greatly reduce execution times.

### Testing
- The suite was executed against by the [flaky test
runner](https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/1804)
multiple times with no failures
- Test data is bundled in two archives (one for metricbeat and one for
package data) and can be loaded to verify their content: `node
scripts/es_archiver.js load
x-pack/test/monitoring_api_integration/archives/elasticsearch/single_node/(package|metricbeat)
--es-url=http://elastic:changeme@localhost:9200
--kibana-url=http://elastic:changeme@localhost:5601`

---------

Co-authored-by: Kibana Machine <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment