mirror of
https://github.com/elastic/kibana.git
synced 2025-04-25 10:23:14 -04:00
[ML] APM Correlations: Fix percentiles values. (#116639)
A change in the ES range agg no longer accepts numbers with decimals if the underlying field is typed as long. This PR fixes the issue by rounding the percentiles values we pass on to the range agg.
This commit is contained in:
parent
c7f7cd39f5
commit
0593c614a9
1 changed files with 5 additions and 1 deletions
|
@ -151,7 +151,11 @@ export const latencyCorrelationsSearchServiceProvider: LatencyCorrelationsSearch
|
|||
params,
|
||||
percentileAggregationPercents
|
||||
);
|
||||
const percentiles = Object.values(percentilesRecords);
|
||||
|
||||
// We need to round the percentiles values
|
||||
// because the queries we're using based on it
|
||||
// later on wouldn't allow numbers with decimals.
|
||||
const percentiles = Object.values(percentilesRecords).map(Math.round);
|
||||
|
||||
addLogMessage(`Loaded percentiles.`);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue