-
Notifications
You must be signed in to change notification settings - Fork 25.2k
[FEATURE][ML] Write data frame configuration to process #35914
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
[FEATURE][ML] Write data frame configuration to process #35914
Conversation
Pinging @elastic/ml-core |
builder.startObject(); | ||
builder.field(NAME.getPreferredName(), name); | ||
builder.endObject(); | ||
return null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return builder I guess?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oups! Indeed!
try (OutputStreamWriter osw = new OutputStreamWriter(Files.newOutputStream(configFile),StandardCharsets.UTF_8); | ||
XContentBuilder jsonBuilder = JsonXContent.contentBuilder()) { | ||
|
||
config.toXContent(jsonBuilder, Payload.XContent.EMPTY_PARAMS); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ToXContent.EMPTY_PARAMS
removes the strange dep to watcher
builder.field(THREADS, threads); | ||
builder.field(ANALYSIS, analysis); | ||
builder.endObject(); | ||
return null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return builder?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
No description provided.