Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[8.17] [Obs AI Assistant] fix knowledge base installation state (#206130
) (#206837) # Backport This will backport the following commits from `main` to `8.17`: - [[Obs AI Assistant] fix knowledge base installation state (#206130)](#206130) <!--- Backport version: 9.6.4 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Sandra G","email":"neptunian@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-01-15T14:38:07Z","message":"[Obs AI Assistant] fix knowledge base installation state (#206130)\n\nResolves https://github.com/elastic/kibana/issues/205970\r\n\r\nUpdates logic to account for knowledge base `/setup` no longer polling\r\nfor model readiness before returning.\r\n\r\n- Currently we only poll `/status` if user manually installs the\r\nknowledge base. In cases where we auto installed, such as after\r\nsuccessfully setting up a connector, we depended on `/setup` to poll\r\ninternally. Since the latter was removed, we need to always poll\r\n`/status`, otherwise user could potentially be in the state where\r\n`setup` has finished (considered installed) but `status` still reports\r\nnot ready and we show the install message again (see screenshots in\r\nhttps://github.com//issues/205970)\r\n- Currently if an install is in progress and user closes the flyout, the\r\nprogress state is lost. These changes should continue to reflect the\r\ninstallation progress in the UI.\r\n- Renames variables and adds comments for easier readability\r\n- adds unit test to component that handles the install UI state,\r\n`WelcomeMessageKnowledgeBase`\r\n\r\n---------\r\n\r\nCo-authored-by: Søren Louv-Jansen <sorenlouv@gmail.com>","sha":"06526fe928ac98580e6fe02768b3c403184694f1","branchLabelMapping":{"^v9.0.0$":"main","^v8.18.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","v9.0.0","ci:cloud-deploy","Team:Obs AI Assistant","ci:project-deploy-elasticsearch","ci:project-deploy-observability","backport:version","v8.18.0","v8.17.1"],"title":"[Obs AI Assistant] fix knowledge base installation state","number":206130,"url":"https://github.com/elastic/kibana/pull/206130","mergeCommit":{"message":"[Obs AI Assistant] fix knowledge base installation state (#206130)\n\nResolves https://github.com/elastic/kibana/issues/205970\r\n\r\nUpdates logic to account for knowledge base `/setup` no longer polling\r\nfor model readiness before returning.\r\n\r\n- Currently we only poll `/status` if user manually installs the\r\nknowledge base. In cases where we auto installed, such as after\r\nsuccessfully setting up a connector, we depended on `/setup` to poll\r\ninternally. Since the latter was removed, we need to always poll\r\n`/status`, otherwise user could potentially be in the state where\r\n`setup` has finished (considered installed) but `status` still reports\r\nnot ready and we show the install message again (see screenshots in\r\nhttps://github.com//issues/205970)\r\n- Currently if an install is in progress and user closes the flyout, the\r\nprogress state is lost. These changes should continue to reflect the\r\ninstallation progress in the UI.\r\n- Renames variables and adds comments for easier readability\r\n- adds unit test to component that handles the install UI state,\r\n`WelcomeMessageKnowledgeBase`\r\n\r\n---------\r\n\r\nCo-authored-by: Søren Louv-Jansen <sorenlouv@gmail.com>","sha":"06526fe928ac98580e6fe02768b3c403184694f1"}},"sourceBranch":"main","suggestedTargetBranches":["8.17"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/206130","number":206130,"mergeCommit":{"message":"[Obs AI Assistant] fix knowledge base installation state (#206130)\n\nResolves https://github.com/elastic/kibana/issues/205970\r\n\r\nUpdates logic to account for knowledge base `/setup` no longer polling\r\nfor model readiness before returning.\r\n\r\n- Currently we only poll `/status` if user manually installs the\r\nknowledge base. In cases where we auto installed, such as after\r\nsuccessfully setting up a connector, we depended on `/setup` to poll\r\ninternally. Since the latter was removed, we need to always poll\r\n`/status`, otherwise user could potentially be in the state where\r\n`setup` has finished (considered installed) but `status` still reports\r\nnot ready and we show the install message again (see screenshots in\r\nhttps://github.com//issues/205970)\r\n- Currently if an install is in progress and user closes the flyout, the\r\nprogress state is lost. These changes should continue to reflect the\r\ninstallation progress in the UI.\r\n- Renames variables and adds comments for easier readability\r\n- adds unit test to component that handles the install UI state,\r\n`WelcomeMessageKnowledgeBase`\r\n\r\n---------\r\n\r\nCo-authored-by: Søren Louv-Jansen <sorenlouv@gmail.com>","sha":"06526fe928ac98580e6fe02768b3c403184694f1"}},{"branch":"8.x","label":"v8.18.0","branchLabelMappingKey":"^v8.18.0$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/206777","number":206777,"state":"OPEN"},{"branch":"8.17","label":"v8.17.1","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT-->
- Loading branch information