diff --git a/x-pack/plugins/infra/server/routes/overview/lib/create_top_nodes_query.ts b/x-pack/plugins/infra/server/routes/overview/lib/create_top_nodes_query.ts index 20bf2324c29d1..1419971db175b 100644 --- a/x-pack/plugins/infra/server/routes/overview/lib/create_top_nodes_query.ts +++ b/x-pack/plugins/infra/server/routes/overview/lib/create_top_nodes_query.ts @@ -142,7 +142,7 @@ export const createTopNodesQuery = ( timeseries: { date_histogram: { field: '@timestamp', - fixed_interval: '1m', + fixed_interval: options.bucketSize, extended_bounds: { min: options.timerange.from, max: options.timerange.to, diff --git a/x-pack/test/api_integration/apis/metrics_ui/metrics_overview_top.ts b/x-pack/test/api_integration/apis/metrics_ui/metrics_overview_top.ts index b3b3f53d6d6c3..0d88e78841f8e 100644 --- a/x-pack/test/api_integration/apis/metrics_ui/metrics_overview_top.ts +++ b/x-pack/test/api_integration/apis/metrics_ui/metrics_overview_top.ts @@ -47,6 +47,7 @@ export default function ({ getService }: FtrProviderContext) { expect(series.length).to.be(1); expect(series[0].id).to.be('demo-stack-mysql-01'); + expect(series[0].timeseries[1].timestamp - series[0].timeseries[0].timestamp).to.be(300_000); }); }); }