-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
Fix visualizations for rollups using fixed_interval or calendar_interval #39537
Fix visualizations for rollups using fixed_interval or calendar_interval #39537
Conversation
Pinging @elastic/kibana-app |
@@ -56,7 +56,7 @@ export function initEditorConfig() { | |||
|
|||
// Set date histogram time zone based on rollup capabilities | |||
if (aggTypeName === 'date_histogram') { | |||
const interval = fieldAgg.interval; | |||
const interval = fieldAgg.fixed_interval ? fieldAgg.fixed_interval : fieldAgg.interval; |
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.
Should this actually use the logic fixed_interval || calendar_interval || interval
? #36306
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.
Yes, it should...
💚 Build Succeeded |
@timroes I'd appreciate any suggestion on who to reach out to for review |
Need to update this because rollups are also using calendar_interval #36310 |
💔 Build Failed |
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.
Code LGTM! I tested locally to make sure that both calendar and fixed rollup indices allow the correct interval inputs, their requests are sent correctly with either calendar_interval
or fixed_interval
, and that their visualizations render.
@jen-huang out of curiosity and so we can track this: Since 7.3 rollup jobs created by Kibana will have a cc @alexwizp |
💚 Build Succeeded |
@timroes I checked with Zack (@polyfractal) and he will look into whether we will leave |
If you don't need an answer immediately, I'm going to bring this up at the weekly meeting and collect some feedback. The original plan was indeed 8.0... but considering the scope of the change (everyone who uses a date_histo, kibana or otherwise) it might be worth leaving this deprecated for a long time. That said, we can probably "upgrade" rollup configs to fixed/calendar automatically. Internally it already upgrades to the correct type when it encounters a legacy |
@polyfractal @jen-huang Based on that feedback, it seems like the rollup jobs could still contain |
@wylieconlon I don't think there are any changes needed given that information. so feel free to merge it. |
Yeah that's correct, jobs that were created pre-7.2 will still have |
💔 Build Failed |
💔 Build Failed |
Jenkins, test this |
💔 Build Failed |
Jenkins, test this. More flakiness |
💚 Build Succeeded |
…val (elastic#39537) * Fix visualizations for rollups using fixed_interval * Update to support calendar_interval as well
…val (elastic#39537) * Fix visualizations for rollups using fixed_interval * Update to support calendar_interval as well
Summary
Visualizations on rollup index patterns were failing due to improper use of the interval value. Fixes #36295
Steps to reproduce the bug:
fixed_interval
in the index pattern.calendar_interval
in the index pattern.Checklist
Use
strikethroughsto remove checklist items you don't feel are applicable to this PR.[ ] This was checked for cross-browser compatibility, including a check against IE11[ ] Any text added follows EUI's writing guidelines, uses sentence case text and includes i18n support[ ] Documentation was added for features that require explanation or tutorials[ ] This was checked for keyboard-only and screenreader accessibilityFor maintainers