[ML] Fix PyTorchModelIT::testDeploymentStats#81161
Merged
davidkyle merged 2 commits intoelastic:masterfrom Dec 1, 2021
Merged
Conversation
Collaborator
|
Pinging @elastic/ml-core (Team:ML) |
Collaborator
💔 Backport failed
You can use sqren/backport to manually backport by running |
davidkyle
added a commit
to davidkyle/elasticsearch
that referenced
this pull request
Dec 1, 2021
Adjusts the test's expectations about the information available when deployments are in the `starting` state
elasticsearchmachine
pushed a commit
that referenced
this pull request
Dec 1, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PyTorchModelIT::testDeploymentStatshas been failing in #80819 due to missing fields in the GET stats response. The problem is in the test as it has the wrong expectations about what is returned when a deployment isstartingThe only way a stats response can be constructed like this is if there are no task responses from the individual nodes and only the nodes for
startedmodels are included in the GET stats requesthttps://github.com/elastic/elasticsearch/blob/master/x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/action/TransportGetDeploymentStatsAction.java#L123
The task request will never be sent to a node hosting a single model in the
startingstate. This is by design as those responses are built on the co-ordinating node. The test passed most of the time because the response is valid if the model isstartedon at least 1 node.As to why sometimes the 2nd GET stats call failed this is because the 2 ml nodes have different views of the trained model allocation, one node knows the model is started there but the other doesn't. GET stats is not a master node action but the responses will be eventually consistent.
Closes #80819