Skip to content

Commit

Permalink
run queries concurrently
Browse files Browse the repository at this point in the history
  • Loading branch information
alexwizp committed May 4, 2021
1 parent bf17be8 commit 6fe3164
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,10 @@ export const getStats = async (
}
}

await doTelemetryFoVisualizations(soClient, telemetryUseLastValueMode);
await doTelemetryForByValueVisualizations(soClient, telemetryUseLastValueMode);
await Promise.all([
doTelemetryFoVisualizations(soClient, telemetryUseLastValueMode),
doTelemetryForByValueVisualizations(soClient, telemetryUseLastValueMode),
]);

return timeseriesUsage.timeseries_use_last_value_mode_total ? timeseriesUsage : undefined;
};

0 comments on commit 6fe3164

Please sign in to comment.