Merge "Improve concurrency access for updateMetrics()"