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

[ML] Adds created_by job property for the advanced wizard #167021

Conversation

jgowdyelastic
Copy link
Member

@jgowdyelastic jgowdyelastic commented Sep 22, 2023

Adds created_by property of advanced-wizard to all jobs created by the advanced job wizard.
Previously no created_by property was added to these jobs.

When cloning, jobs with no created_by property or one with a value of advanced-wizard will be opened in the advanced wizard.

Closes #166053

@jgowdyelastic jgowdyelastic marked this pull request as ready for review September 22, 2023 12:23
@jgowdyelastic jgowdyelastic requested a review from a team as a code owner September 22, 2023 12:23
@elasticmachine
Copy link
Contributor

Pinging @elastic/ml-ui (:ml)

@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
ml 3.5MB 3.5MB +133.0B

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @jgowdyelastic

@@ -240,7 +241,12 @@ export async function cloneJob(jobId) {
return;
}

if (cloneableJob !== undefined && originalJob?.custom_settings?.created_by !== undefined) {
const createdBy = originalJob?.custom_settings?.created_by;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When I export jobs, looks like created_by is removed (tried an advanced job and a multi-metric one). I can't remember - was this intentional?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We're using the flag exclude_generated: true when retrieving the jobs from es. This removes the created_by prop.
If we think it would be better to not strip this out, I can change it in a separate PR.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds a good idea to retain created_by on export, and to do it in a separate PR.

Copy link
Contributor

@peteharverson peteharverson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and LGTM.

As discussed, let's retain the created_by field on export in a separate PR.

Copy link
Contributor

@alvarezmelissa87 alvarezmelissa87 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM ⚡

@jgowdyelastic jgowdyelastic merged commit 302ec10 into elastic:main Sep 26, 2023
20 checks passed
@kibanamachine kibanamachine added the backport:skip This commit does not require backporting label Sep 26, 2023
jgowdyelastic added a commit that referenced this pull request Sep 27, 2023
…167319)

When exporting an anomaly detection job, it would be useful if the
original `created_by` property was not removed from the job config.


Related to
#167021 (comment)
Related PR #88898
@szabosteve szabosteve changed the title [ML] Adding created_by job property for the advanced wizard [ML] Adds created_by job property for the advanced wizard Oct 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting Feature:Anomaly Detection ML anomaly detection :ml release_note:enhancement v8.11.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ML] Set created_by attribute to indicate jobs created in advanced anomaly detection wizard
6 participants