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] Changes group-by and agg names. #36686

Merged
merged 3 commits into from May 21, 2019

Conversation

walterra
Copy link
Contributor

@walterra walterra commented May 20, 2019

Summary

So far the groupby/agg name shown in the dropdowns and the name used for the ES config agg name has been the same.

This PR changes the behaviour to the following:

  1. group_by aggregation names will be left as original e.g. clientip, timestamp
  2. agg functions will be added to the end as a nested object e.g. doc.bytes.sent.sum and doc.bytes.sent.avg and duration.max
  3. the drop down display labels in the pickers in the wizard will continue to use the sql-like notation e.g. date_histogram(timestamp), terms(clientip), sum(doc.bytes.sent), max(duration)
  4. when auto-generating aggregation names, unsupported characters ([]>) will be removed.

Checklist

Use strikethroughs to remove checklist items you don't feel are applicable to this PR.

@walterra walterra self-assigned this May 20, 2019
@walterra walterra added :ml release_note:skip Skip the PR/issue when compiling release notes v7.2.0 v8.0.0 labels May 20, 2019
@elasticmachine
Copy link
Contributor

Pinging @elastic/ml-ui

@walterra walterra marked this pull request as ready for review May 20, 2019 13:27
@walterra walterra requested a review from a team as a code owner May 20, 2019 13:27
@elasticmachine
Copy link
Contributor

💔 Build Failed

@elasticmachine
Copy link
Contributor

💔 Build Failed

@elasticmachine
Copy link
Contributor

💚 Build Succeeded

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 ⚡️

Copy link
Member

@jgowdyelastic jgowdyelastic left a comment

Choose a reason for hiding this comment

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

LGTM

field: fieldName,
interval: '1m',
};
}
}

const illegalEsAggNameChars = /[[\]>]/g;
Copy link
Member

Choose a reason for hiding this comment

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

i would have thought there are a lot more illegal characters for an aggregation name, is there something significant about these ones?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I was surprised too. Originally it was [a-zA-Z0-9\\-_], here's the reference to the elasticsearch PR that changed this: elastic/elasticsearch#6708

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.

Don't suspect it's related to this PR, but the data frame I created when testing this out is stuck at 99%

image

elasticsearch.log doesn't show any errors:

[2019-05-21T09:55:59,904][INFO ][o.e.x.d.t.DataFrameTransformPersistentTasksExecutor] [DESKTOP-RQG9008] Successfully completed and scheduled task in node operation
[2019-05-21T09:56:01,880][WARN ][o.e.x.c.i.AsyncTwoPhaseIndexer] [DESKTOP-RQG9008] Schedule was triggered for job [nginx_bytes_df], but prior indexer is still running (with state [INDEXING]
[2019-05-21T09:56:01,947][INFO ][o.e.x.d.t.DataFrameTransformTask] [DESKTOP-RQG9008] Finished indexing for data frame transform [nginx_bytes_df] checkpoint [1]

@walterra walterra merged commit 5e38499 into elastic:master May 21, 2019
[ML] Transforms UI (7.x) automation moved this from Review to Done (merged to master) May 21, 2019
@walterra walterra deleted the ml-data-frames-groupby-agg-names branch May 21, 2019 09:08
walterra added a commit to walterra/kibana that referenced this pull request May 21, 2019
So far the groupby/agg name shown in the dropdowns and the name used for the ES config agg name has been the same.

This PR changes the behaviour to the following:

- group_by aggregation names will be left as original e.g. clientip, timestamp
- agg functions will be added to the end as a nested object e.g. doc.bytes.sent.sum and doc.bytes.sent.avg and duration.max
- the drop down display labels in the pickers in the wizard will continue to use the sql-like notation e.g. date_histogram(timestamp), terms(clientip), sum(doc.bytes.sent), max(duration)
- when auto-generating aggregation names, unsupported characters ([]>) will be removed.
walterra added a commit that referenced this pull request May 21, 2019
So far the groupby/agg name shown in the dropdowns and the name used for the ES config agg name has been the same.

This PR changes the behaviour to the following:

- group_by aggregation names will be left as original e.g. clientip, timestamp
- agg functions will be added to the end as a nested object e.g. doc.bytes.sent.sum and doc.bytes.sent.avg and duration.max
- the drop down display labels in the pickers in the wizard will continue to use the sql-like notation e.g. date_histogram(timestamp), terms(clientip), sum(doc.bytes.sent), max(duration)
- when auto-generating aggregation names, unsupported characters ([]>) will be removed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:ml release_note:skip Skip the PR/issue when compiling release notes v7.2.0 v8.0.0
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

None yet

5 participants