[Synthetics] Migrate synthetics alerting API tests to deployment agnostic solution#221139
[Synthetics] Migrate synthetics alerting API tests to deployment agnostic solution#221139cesco-f merged 9 commits intoelastic:mainfrom
Conversation
7af4b85 to
77d7f05
Compare
77d7f05 to
db0c5cb
Compare
wayneseymour
left a comment
There was a problem hiding this comment.
Reviewed files owned by my team:
- x-pack/test/api_integration/deployment_agnostic/default_configs/serverless.config.base.ts
- x-pack/test/api_integration/deployment_agnostic/default_configs/stateful.config.base.ts
- x-pack/test/api_integration/deployment_agnostic/services/alerting_api.ts
CR only, LGTM, as long as the tests pass, specifically I'm curious about the bool filter added to the alerting api. But again, if the tests pass, I'm good with it.
In the current implementation of |
47893c3 to
e6a28bb
Compare
💚 Build Succeeded
Metrics [docs]Unknown metric groupsESLint disabled line counts
Total ESLint disabled count
History
|
e6a28bb to
9e23dd7
Compare
24e27f4 to
f98245c
Compare
f98245c to
ad30646
Compare
🤖 GitHub commentsExpand to view the GitHub comments
Just comment with:
|
ad30646 to
dc8d196
Compare
💚 Build Succeeded
Metrics [docs]Unknown metric groupsESLint disabled line counts
Total ESLint disabled count
History
|
| logger: this.logger, | ||
| indexName: '.internal.alerts-observability.uptime.alerts-default*', | ||
| retryDelay: 1000, | ||
| indexName: '.alerts-observability.uptime.alerts-default*', |
There was a problem hiding this comment.
Is there any reason why .internal.alerts-observability.uptime.alerts-default was changed to '.alerts-observability.uptime.alerts-default*'
There was a problem hiding this comment.
Apparently in stateful the index is .internal.alerts-observability.uptime.alerts-default while in serverless is .ds-.alerts-observability.uptime.alerts-default, so I'm using the alias as suggested by @kdelemme and it works for both environments.
I had similar question, but as long as tests are happy with it, I am happy as well! And yep it makes sense to change it like this, since Synthetics passes additional filters |
| ], | ||
| }); | ||
| expect(recoveredResponse.hits.hits[1]._source).property( | ||
| expect(recoveredResponse.hits.hits[0]._source).property( |
There was a problem hiding this comment.
Wondering why hits[1] was changed to hits[0]
There was a problem hiding this comment.
This test was flaky because we were fetching all the alerts and assuming that the recovered alert was in position 1. But this was not always the case (no idea why) and sometimes it was failing.
So I changed the test to fetch only the recovered alerts, I'm expecting to get only 1 result and so that's why it was changed to hits[0].
|
Starting backport for target branches: 8.19 https://github.com/elastic/kibana/actions/runs/15321651132 |
💔 All backports failed
Manual backportTo create the backport manually run: Questions ?Please refer to the Backport tool documentation |
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…stic solution (elastic#221139) This PR closes elastic#212954. Synthetics alerting API tests have been migrated to deployment agnostic solution. ### 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="Synthetics Alerting" ``` ### 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="Synthetics Alerting" ```
…nt agnostic solution (#221139) (#221908) # Backport This will backport the following commits from `main` to `8.19`: - [[Synthetics] Migrate synthetics alerting API tests to deployment agnostic solution (#221139)](#221139) <!--- Backport version: 10.0.0 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Francesco Fagnani","email":"fagnani.francesco@gmail.com"},"sourceCommit":{"committedDate":"2025-05-29T10:18:52Z","message":"[Synthetics] Migrate synthetics alerting API tests to deployment agnostic solution (#221139)\n\nThis PR closes #212954.\n\nSynthetics alerting API tests have been migrated to deployment agnostic\nsolution.\n\n### Serverless\n```\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts\n\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts --grep=\"Synthetics Alerting\"\n```\n\n### Stateful\n```\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts\n\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts --grep=\"Synthetics Alerting\"\n```","sha":"fdebd18bfd5b525d69d4a53911c84d7e2843d01b","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","ci:project-deploy-observability","backport:version","v9.1.0","v8.19.0","author:obs-ux-management"],"title":"[Synthetics] Migrate synthetics alerting API tests to deployment agnostic solution","number":221139,"url":"https://github.com/elastic/kibana/pull/221139","mergeCommit":{"message":"[Synthetics] Migrate synthetics alerting API tests to deployment agnostic solution (#221139)\n\nThis PR closes #212954.\n\nSynthetics alerting API tests have been migrated to deployment agnostic\nsolution.\n\n### Serverless\n```\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts\n\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts --grep=\"Synthetics Alerting\"\n```\n\n### Stateful\n```\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts\n\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts --grep=\"Synthetics Alerting\"\n```","sha":"fdebd18bfd5b525d69d4a53911c84d7e2843d01b"}},"sourceBranch":"main","suggestedTargetBranches":["8.19"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/221139","number":221139,"mergeCommit":{"message":"[Synthetics] Migrate synthetics alerting API tests to deployment agnostic solution (#221139)\n\nThis PR closes #212954.\n\nSynthetics alerting API tests have been migrated to deployment agnostic\nsolution.\n\n### Serverless\n```\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts\n\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts --grep=\"Synthetics Alerting\"\n```\n\n### Stateful\n```\nnode scripts/functional_tests_server --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts\n\nnode scripts/functional_test_runner --config x-pack/test/api_integration/deployment_agnostic/configs/stateful/oblt.stateful.config.ts --grep=\"Synthetics Alerting\"\n```","sha":"fdebd18bfd5b525d69d4a53911c84d7e2843d01b"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT-->
Relocating tests added in #221139 into separate feature flag configs, that are not run on MKI but only Kibana CI. --------- Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
…stic solution (elastic#221139) This PR closes elastic#212954. Synthetics alerting API tests have been migrated to deployment agnostic solution. ### 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="Synthetics Alerting" ``` ### 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="Synthetics Alerting" ```
…c#222371) Relocating tests added in elastic#221139 into separate feature flag configs, that are not run on MKI but only Kibana CI. --------- Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
…stic solution (elastic#221139) This PR closes elastic#212954. Synthetics alerting API tests have been migrated to deployment agnostic solution. ### 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="Synthetics Alerting" ``` ### 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="Synthetics Alerting" ```
…c#222371) Relocating tests added in elastic#221139 into separate feature flag configs, that are not run on MKI but only Kibana CI. --------- Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
…222371) (#224588) # Backport This will backport the following commits from `main` to `8.19`: - [[FTR] add feature flags configs for deployment-agnostic tests (#222371)](#222371) Also cherry-picked a few required changes from #218725 which was not backported. <!--- Backport version: 10.0.1 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Dzmitry Lemechko","email":"dzmitry.lemechko@elastic.co"},"sourceCommit":{"committedDate":"2025-06-04T13:57:03Z","message":"[FTR] add feature flags configs for deployment-agnostic tests (#222371)\n\nRelocating tests added in #221139 into separate feature flag configs,\nthat are not run on MKI but only Kibana CI.\n\n---------\n\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>","sha":"966f73481d6cfb25c59f363149e302b9b9fa40a2","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","backport missing","backport:version","v9.1.0","v8.19.0"],"title":"[FTR] add feature flags configs for deployment-agnostic tests","number":222371,"url":"https://github.com/elastic/kibana/pull/222371","mergeCommit":{"message":"[FTR] add feature flags configs for deployment-agnostic tests (#222371)\n\nRelocating tests added in #221139 into separate feature flag configs,\nthat are not run on MKI but only Kibana CI.\n\n---------\n\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>","sha":"966f73481d6cfb25c59f363149e302b9b9fa40a2"}},"sourceBranch":"main","suggestedTargetBranches":["8.19"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/222371","number":222371,"mergeCommit":{"message":"[FTR] add feature flags configs for deployment-agnostic tests (#222371)\n\nRelocating tests added in #221139 into separate feature flag configs,\nthat are not run on MKI but only Kibana CI.\n\n---------\n\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>","sha":"966f73481d6cfb25c59f363149e302b9b9fa40a2"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> --------- Co-authored-by: Dzmitry Lemechko <dzmitry.lemechko@elastic.co>


This PR closes #212954.
Synthetics alerting API tests have been migrated to deployment agnostic solution.
Serverless
Stateful