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

[8.x] [ML] Trained Model: Fix start deployment with ML autoscaling and 0 active nodes (#201256) #201748

Merged
merged 1 commit into from
Nov 26, 2024

Conversation

kibanamachine
Copy link
Contributor

Backport

This will backport the following commits from main to 8.x:

Questions ?

Please refer to the Backport tool documentation

…tive nodes (elastic#201256)

## Summary

During my testing, I used the current user with all required privileges
but failed to notice that, after switching to the internal`
kibana_system` user, it lacked the manage_autoscaling privilege required
for the `GET /_autoscaling/policy` API.

As a result, the `isMlAutoscalingEnabled` flag, which we rely on in the
Start Deployment modal, was always set to false. This caused a bug in
scenarios with zero active ML nodes, where falling back to deriving
available processors from ML limits was not possible.

You can check the created deployment, it correctly identifies ML
autoscaling:

<img width="670" alt="image"
src="https://github.com/user-attachments/assets/ff1f835e-2b90-4b73-bea8-a49da8846fbd">

Also fixes restoring vCPU levels from the API deployment params.

### Checklist

Check the PR satisfies following conditions.

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

(cherry picked from commit 9827a07)
@kibanamachine kibanamachine merged commit c6b22ca into elastic:8.x Nov 26, 2024
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants