[ML] Job In Index: Enable GET APIS in mixed state#35344
Merged
davidkyle merged 10 commits intoelastic:feature-jindex-6xfrom Nov 13, 2018
Merged
[ML] Job In Index: Enable GET APIS in mixed state#35344davidkyle merged 10 commits intoelastic:feature-jindex-6xfrom
davidkyle merged 10 commits intoelastic:feature-jindex-6xfrom
Conversation
This enables calls to the get job/stats APIs in a mixed cluster state before jobs have been migrated
Plus tests and fixes to expandJobs
All calls should use the calls that also check the cluster state
Collaborator
|
Pinging @elastic/ml-core |
43 tasks
benwtrent
reviewed
Nov 8, 2018
Member
benwtrent
left a comment
There was a problem hiding this comment.
Whew, pretty big PR. Found a couple of small things.
Will probably have to read through it all again to fully absorb it :D
...gin/ml/src/main/java/org/elasticsearch/xpack/ml/action/TransportGetDatafeedsStatsAction.java
Outdated
Show resolved
Hide resolved
x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/datafeed/DatafeedConfigReader.java
Outdated
Show resolved
Hide resolved
x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/job/JobManager.java
Show resolved
Hide resolved
benwtrent
reviewed
Nov 9, 2018
Member
benwtrent
left a comment
There was a problem hiding this comment.
One last comment, and after clarification/correct, I think this looks good.
...k/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/action/TransportGetDatafeedsAction.java
Show resolved
Hide resolved
benwtrent
approved these changes
Nov 9, 2018
Member
benwtrent
left a comment
There was a problem hiding this comment.
LGTM, due to the size, do we want another 👍 ?
Member
Author
|
I'm working on a follow up PR with much more rigorous testing in it which I didn't want to add to this one due to the size so I think we're ok with one review. I expect the upgrade tests I'm working on to flush out more bugs |
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.
Jobs left open during an upgrade to 6.6 will not be migrated so this version must support running jobs that are stored in either the cluster state or index documents. New jobs will be stored as documents but old jobs will continue to run from the clusterstate. To achieve this the job and datafeed operations should look in both the clusterstate and the index for the configuration, this is the first change towards that goal and covers reading the configurations.
DatafeedConfigReaderas a wrapper around DatafeedConfigProvider but checks both cluster state and index for configurationAll methods to get the configs go through these 2 classes.
This meant I had to change
NameResolverto not throw on missing jobs as I now collect the clusterstate and index jobs and useExpandedIdsMatcherto check the required job ids, datafeed ids and job groups are present.Rolling upgrade tests to follow but this is already a large PR