Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[8.x] [Onboarding] Remove retrying when fetch index API query fails (e…
…lastic#193634) (elastic#194173) # Backport This will backport the following commits from `main` to `8.x`: - [[Onboarding] Remove retrying when fetch index API query fails (elastic#193634)](elastic#193634) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Saarika Bhasi","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-09-26T15:08:32Z","message":"[Onboarding] Remove retrying when fetch index API query fails (elastic#193634)\n\n## Summary\r\n\r\nThis Pr set retrying to `false` when fetch Index api returns 404 status.\r\nFor all other status code, the fetch index api is retried until failure\r\ncount is 3.\r\n\r\nAlso updated error component to show error message returned from\r\nelasticsearch\r\n\r\n### screenshot\r\n\r\n**Status code: 404** \r\n\r\n<img width=\"1286\" alt=\"Screenshot 2024-09-25 at 11 07 20 AM\"\r\nsrc=\"https://github.com/user-attachments/assets/982b5037-b8a5-43d7-bd5f-874929a74ede\">\r\n\r\n**Status code: 500** \r\n<img width=\"1286\" alt=\"Screenshot 2024-09-25 at 11 16 26 AM\"\r\nsrc=\"https://github.com/user-attachments/assets/7b7ecbbe-14af-4d9d-8107-bcee9fa384bf\">\r\n\r\n**How to test:** \r\n1. Enable searchIndices plugin in `kibana.dev.yml` as this plugin is\r\nbehind Feature flag\r\n```\r\nxpack.searchIndices.enabled: true\r\n\r\n```\r\n2. [Create new\r\nindex](https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-create-index.html)\r\n3. Navigate to\r\n`/app/elasticsearch/indices/index_details/${indexName}/data`\r\n4. [ Delete\r\nindex](https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-delete-index.html)\r\n5. Wait for the error screen to appear. Note error message is shown\r\nafter one `/internal/index_management/indices/my-index` API is failed\r\n\r\n### Checklist\r\n\r\nDelete any items that are not applicable to this PR.\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n- [x] [Flaky Test\r\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was\r\nused on any tests changed","sha":"2583b961bb37e9f498157efbe1710b8661272eba","branchLabelMapping":{"^v9.0.0$":"main","^v8.16.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","Team:Search","backport:prev-minor","v8.16.0"],"title":"[Onboarding] Remove retrying when fetch index API query fails","number":193634,"url":"https://github.com/elastic/kibana/pull/193634","mergeCommit":{"message":"[Onboarding] Remove retrying when fetch index API query fails (elastic#193634)\n\n## Summary\r\n\r\nThis Pr set retrying to `false` when fetch Index api returns 404 status.\r\nFor all other status code, the fetch index api is retried until failure\r\ncount is 3.\r\n\r\nAlso updated error component to show error message returned from\r\nelasticsearch\r\n\r\n### screenshot\r\n\r\n**Status code: 404** \r\n\r\n<img width=\"1286\" alt=\"Screenshot 2024-09-25 at 11 07 20 AM\"\r\nsrc=\"https://github.com/user-attachments/assets/982b5037-b8a5-43d7-bd5f-874929a74ede\">\r\n\r\n**Status code: 500** \r\n<img width=\"1286\" alt=\"Screenshot 2024-09-25 at 11 16 26 AM\"\r\nsrc=\"https://github.com/user-attachments/assets/7b7ecbbe-14af-4d9d-8107-bcee9fa384bf\">\r\n\r\n**How to test:** \r\n1. Enable searchIndices plugin in `kibana.dev.yml` as this plugin is\r\nbehind Feature flag\r\n```\r\nxpack.searchIndices.enabled: true\r\n\r\n```\r\n2. [Create new\r\nindex](https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-create-index.html)\r\n3. Navigate to\r\n`/app/elasticsearch/indices/index_details/${indexName}/data`\r\n4. [ Delete\r\nindex](https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-delete-index.html)\r\n5. Wait for the error screen to appear. Note error message is shown\r\nafter one `/internal/index_management/indices/my-index` API is failed\r\n\r\n### Checklist\r\n\r\nDelete any items that are not applicable to this PR.\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n- [x] [Flaky Test\r\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was\r\nused on any tests changed","sha":"2583b961bb37e9f498157efbe1710b8661272eba"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/193634","number":193634,"mergeCommit":{"message":"[Onboarding] Remove retrying when fetch index API query fails (elastic#193634)\n\n## Summary\r\n\r\nThis Pr set retrying to `false` when fetch Index api returns 404 status.\r\nFor all other status code, the fetch index api is retried until failure\r\ncount is 3.\r\n\r\nAlso updated error component to show error message returned from\r\nelasticsearch\r\n\r\n### screenshot\r\n\r\n**Status code: 404** \r\n\r\n<img width=\"1286\" alt=\"Screenshot 2024-09-25 at 11 07 20 AM\"\r\nsrc=\"https://github.com/user-attachments/assets/982b5037-b8a5-43d7-bd5f-874929a74ede\">\r\n\r\n**Status code: 500** \r\n<img width=\"1286\" alt=\"Screenshot 2024-09-25 at 11 16 26 AM\"\r\nsrc=\"https://github.com/user-attachments/assets/7b7ecbbe-14af-4d9d-8107-bcee9fa384bf\">\r\n\r\n**How to test:** \r\n1. Enable searchIndices plugin in `kibana.dev.yml` as this plugin is\r\nbehind Feature flag\r\n```\r\nxpack.searchIndices.enabled: true\r\n\r\n```\r\n2. [Create new\r\nindex](https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-create-index.html)\r\n3. Navigate to\r\n`/app/elasticsearch/indices/index_details/${indexName}/data`\r\n4. [ Delete\r\nindex](https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-delete-index.html)\r\n5. Wait for the error screen to appear. Note error message is shown\r\nafter one `/internal/index_management/indices/my-index` API is failed\r\n\r\n### Checklist\r\n\r\nDelete any items that are not applicable to this PR.\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n- [x] [Flaky Test\r\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was\r\nused on any tests changed","sha":"2583b961bb37e9f498157efbe1710b8661272eba"}},{"branch":"8.x","label":"v8.16.0","branchLabelMappingKey":"^v8.16.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Saarika Bhasi <[email protected]>
- Loading branch information