Skip to content

Interval field on DateHistograms will be deprecated #27410

@polyfractal

Description

@polyfractal

Today, Elasticsearch's date_histogram aggregation's interval field supports both "fixed" and "calendar" time simultaneously, choosing between the two depending on the interval's syntax (e.g. 1d is calendar, 2d is fixed). This is super confusing for users even if they read the documentation, and a very subtle bug for everyone else because intervals don't always work as they expect.

Elasticsearch is working on a PR to deprecate this functionality, and replace it with two explicit fields: fixed_interval and calendar_interval. This way the user knows exactly what they are getting.

The plan as it stands today:

  • Add fixed_interval / calendar_interval fields to date_histogram aggregation.
  • Deprecate interval field in 7.0+
  • Remove interval field in 8.0
  • All three fields are mutually exclusive
  • Changes also affect rollup configurations and composite aggs (since they both use the date_histo)

More details can be found in the PR itself (elastic/elasticsearch#33727) but I wanted to open an issue in Kibana to track the deprecation since it'll affect anything touching a date histo.

Note: we're targeting 7.0, but there's no requirement it has to make 7.0 so it could slip to 7.x

TODOs

Metadata

Metadata

Assignees

No one assigned

    Labels

    Feature:AggregationsAggregation infrastructure (AggConfig, esaggs, ...)Feature:RollupsTeam:Kibana ManagementDev Tools, Index Management, Upgrade Assistant, ILM, Ingest Node Pipelines, and more t//Team:MonitoringStack Monitoring teamTeam:VisualizationsTeam label for Lens, elastic-charts, Graph, legacy editors (TSVB, Visualize, Timelion) t//release_note:breaking

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions