In case you have your own slow SQL query, you can optimize it automatically here.
For the query above, the following recommendations will be helpful as part of the SQL tuning process.
You'll find 3 sections below:
ALTER TABLE `traffic_data_replica` ADD INDEX `traffic_replica_idx_date_id` (`date`,`id`);
SELECT
Sum(1.0 * traffic_data_replica.volume * traffic_data_replica.speed) / Sum(traffic_data_replica.volume) AS aggregated_speed
FROM
traffic_data_replica
GROUP BY
traffic_data_replica.date,
traffic_data_replica.id
ORDER BY
traffic_data_replica.date