The metrics data returned by Ambari that is displayed on the charts seems to have different granularity for different periods in a single time series on a chart.
The AMS cache layer running on the Ambari server requests the metrics data only for the delta period (period for which the data is not present in the cache) to the AMS. The bug was that the precision of the data requested (or computed) was not taken into account during this delta request.
Objective of this patch
Incorporate the difference between precision of the data in the cache and the requested precision of the data while requesting from AMS.