-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
Migrate /diagnostics and /service_nodes to be deployment agnostic #199645
Migrate /diagnostics and /service_nodes to be deployment agnostic #199645
Conversation
…agnostic API tests
…testapm_api_integrationtestsdiagnostics-to-be-deployment-agnostic-api-tests
…testapm_api_integrationtestsdiagnostics-to-be-deployment-agnostic-api-tests
…testapm_api_integrationtestsdiagnostics-to-be-deployment-agnostic-api-tests
Flaky Test Runner Stats🎉 All tests passed! - kibana-flaky-test-suite-runner#7390[✅] x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts: 25/25 tests passed. |
…t-agnostic API tests
…nodes-to-be-deployment-agnostic-api-tests' into 198967-apm-migrate-testapm_api_integrationtestsdiagnostics-to-be-deployment-agnostic-api-tests
}) | ||
); | ||
|
||
const apmTemplateNames = uniqueTemplateNames.filter((templateName) => |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We filter out only apm
and otel
index templates for the test, otherwise they differ on serverless and test fails
Pinging @elastic/obs-ux-infra_services-team (Team:obs-ux-infra_services) |
🤖 GitHub commentsExpand to view the GitHub comments
Just comment with:
|
const synthtrace = getService('synthtrace'); | ||
|
||
const start = new Date('2021-01-01T00:00:00.000Z').getTime(); | ||
const end = new Date('2021-01-01T00:15:00.000Z').getTime() - 1; | ||
|
||
describe.skip('Diagnostics: Index pattern settings', () => { | ||
describe('When there is no data', () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When default index templates are deleted, they get recreated automatically. It was introduced here: elastic/elasticsearch#97546
This means we can't perform check against empty response anymore.
@@ -19,27 +18,7 @@ export default function ApiTest({ getService }: DeploymentAgnosticFtrProviderCon | |||
const start = new Date('2021-01-01T00:00:00.000Z').getTime(); | |||
const end = new Date('2021-01-01T00:15:00.000Z').getTime() - 1; | |||
|
|||
describe.skip('Diagnostics: Index Templates', () => { | |||
describe('When there is no data', () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When default index templates are deleted, they get recreated automatically. Introduced here: elastic/elasticsearch#97546
This means we can't perform check against empty response anymore.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, small change requested
x-pack/test/api_integration/deployment_agnostic/apis/observability/apm/service_nodes/index.ts
Outdated
Show resolved
Hide resolved
Co-authored-by: Sergi Romeu <[email protected]>
…stsdiagnostics-to-be-deployment-agnostic-api-tests
@@ -9,19 +9,18 @@ import expect from '@kbn/expect'; | |||
import { apm, timerange } from '@kbn/apm-synthtrace-client'; | |||
import { APIReturnType } from '@kbn/apm-plugin/public/services/rest/create_call_apm_api'; | |||
import { sumBy } from 'lodash'; | |||
import { FtrProviderContext } from '../../common/ftr_provider_context'; | |||
import { ApmSynthtraceEsClient } from '@kbn/apm-synthtrace'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit.
import { ApmSynthtraceEsClient } from '@kbn/apm-synthtrace'; | |
import type { ApmSynthtraceEsClient } from '@kbn/apm-synthtrace'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I updated all /apm/*
tests by adding type-only imports.
const apmSynthtraceKibanaClient = synthtrace.apmSynthtraceKibanaClient; | ||
const latestVersion = await apmSynthtraceKibanaClient.fetchLatestApmPackageVersion(); | ||
await apmSynthtraceKibanaClient.installApmPackage(latestVersion); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
createApmSynthtraceEsClient
already installs the latest apm package version. Why is this needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for review. Those were remainings from the old test and I didn't notice that apm packge is installed in createApmSynthtraceEsClient
. Updated!
const apmSynthtraceKibanaClient = synthtrace.apmSynthtraceKibanaClient; | ||
const latestVersion = await apmSynthtraceKibanaClient.fetchLatestApmPackageVersion(); | ||
await apmSynthtraceKibanaClient.installApmPackage(latestVersion); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks for the changes.
…testapm_api_integrationtestsdiagnostics-to-be-deployment-agnostic-api-tests
💔 Build Failed
Failed CI StepsMetrics [docs]
History
|
Starting backport for target branches: 8.x https://github.com/elastic/kibana/actions/runs/11840525161 |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation |
Friendly reminder: Looks like this PR hasn’t been backported yet. |
…astic#199645) closes elastic#198967 closes elastic#198985 part of elastic#193245 ### How to test - Serverless ``` node scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts node scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts --grep="APM" ``` - Stateful ``` node scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts node scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts --grep="APM" ``` - [MKI](https://github.com/crespocarlos/kibana/blob/main/x-pack/test_serverless/README.md#run-tests-on-mki) ### Checklist - [x] (OPTIONAL, only if a test has been unskipped) Run flaky test suite - [x] serverless - [x] stateful - [x] MKI --------- Co-authored-by: Sergi Romeu <[email protected]>
…astic#199645) closes elastic#198967 closes elastic#198985 part of elastic#193245 ### How to test - Serverless ``` node scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts node scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts --grep="APM" ``` - Stateful ``` node scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts node scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts --grep="APM" ``` - [MKI](https://github.com/crespocarlos/kibana/blob/main/x-pack/test_serverless/README.md#run-tests-on-mki) ### Checklist - [x] (OPTIONAL, only if a test has been unskipped) Run flaky test suite - [x] serverless - [x] stateful - [x] MKI --------- Co-authored-by: Sergi Romeu <[email protected]>
…astic#199645) closes elastic#198967 closes elastic#198985 part of elastic#193245 ### How to test - Serverless ``` node scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts node scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts --grep="APM" ``` - Stateful ``` node scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts node scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts --grep="APM" ``` - [MKI](https://github.com/crespocarlos/kibana/blob/main/x-pack/test_serverless/README.md#run-tests-on-mki) ### Checklist - [x] (OPTIONAL, only if a test has been unskipped) Run flaky test suite - [x] serverless - [x] stateful - [x] MKI --------- Co-authored-by: Sergi Romeu <[email protected]>
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…astic#199645) closes elastic#198967 closes elastic#198985 part of elastic#193245 ### How to test - Serverless ``` node scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts node scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts --grep="APM" ``` - Stateful ``` node scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts node scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts --grep="APM" ``` - [MKI](https://github.com/crespocarlos/kibana/blob/main/x-pack/test_serverless/README.md#run-tests-on-mki) ### Checklist - [x] (OPTIONAL, only if a test has been unskipped) Run flaky test suite - [x] serverless - [x] stateful - [x] MKI --------- Co-authored-by: Sergi Romeu <[email protected]> (cherry picked from commit 04b2d62)
…ic (#199645) (#200563) # Backport This will backport the following commits from `main` to `8.x`: - [Migrate /diagnostics and /service_nodes to be deployment agnostic (#199645)](#199645) <!--- Backport version: 8.9.8 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Milosz Marcinkowski","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-11-14T15:39:11Z","message":"Migrate /diagnostics and /service_nodes to be deployment agnostic (#199645)\n\ncloses #198967\r\ncloses #198985\r\npart of https://github.com/elastic/kibana/issues/193245\r\n\r\n### How to test\r\n\r\n- Serverless\r\n\r\n```\r\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts\r\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts --grep=\"APM\"\r\n```\r\n\r\n- Stateful\r\n```\r\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts\r\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts --grep=\"APM\"\r\n```\r\n\r\n-\r\n[MKI](https://github.com/crespocarlos/kibana/blob/main/x-pack/test_serverless/README.md#run-tests-on-mki)\r\n\r\n### Checklist\r\n- [x] (OPTIONAL, only if a test has been unskipped) Run flaky test suite\r\n- [x] serverless\r\n- [x] stateful\r\n- [x] MKI\r\n\r\n---------\r\n\r\nCo-authored-by: Sergi Romeu <[email protected]>","sha":"04b2d62fee8731e1a0a6ff230b512d7e94843ce5","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","backport missing","v9.0.0","backport:prev-minor","ci:project-deploy-observability","Team:obs-ux-infra_services"],"number":199645,"url":"https://github.com/elastic/kibana/pull/199645","mergeCommit":{"message":"Migrate /diagnostics and /service_nodes to be deployment agnostic (#199645)\n\ncloses #198967\r\ncloses #198985\r\npart of https://github.com/elastic/kibana/issues/193245\r\n\r\n### How to test\r\n\r\n- Serverless\r\n\r\n```\r\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts\r\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts --grep=\"APM\"\r\n```\r\n\r\n- Stateful\r\n```\r\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts\r\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts --grep=\"APM\"\r\n```\r\n\r\n-\r\n[MKI](https://github.com/crespocarlos/kibana/blob/main/x-pack/test_serverless/README.md#run-tests-on-mki)\r\n\r\n### Checklist\r\n- [x] (OPTIONAL, only if a test has been unskipped) Run flaky test suite\r\n- [x] serverless\r\n- [x] stateful\r\n- [x] MKI\r\n\r\n---------\r\n\r\nCo-authored-by: Sergi Romeu <[email protected]>","sha":"04b2d62fee8731e1a0a6ff230b512d7e94843ce5"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","labelRegex":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/199645","number":199645,"mergeCommit":{"message":"Migrate /diagnostics and /service_nodes to be deployment agnostic (#199645)\n\ncloses #198967\r\ncloses #198985\r\npart of https://github.com/elastic/kibana/issues/193245\r\n\r\n### How to test\r\n\r\n- Serverless\r\n\r\n```\r\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts\r\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts --grep=\"APM\"\r\n```\r\n\r\n- Stateful\r\n```\r\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts\r\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts --grep=\"APM\"\r\n```\r\n\r\n-\r\n[MKI](https://github.com/crespocarlos/kibana/blob/main/x-pack/test_serverless/README.md#run-tests-on-mki)\r\n\r\n### Checklist\r\n- [x] (OPTIONAL, only if a test has been unskipped) Run flaky test suite\r\n- [x] serverless\r\n- [x] stateful\r\n- [x] MKI\r\n\r\n---------\r\n\r\nCo-authored-by: Sergi Romeu <[email protected]>","sha":"04b2d62fee8731e1a0a6ff230b512d7e94843ce5"}}]}] BACKPORT-->
closes #198967
closes #198985
part of #193245
How to test
Checklist