refactor(metrics): replace MetricFactory with MetricsBucket

This approach removes the unnecessary logic in the calling code by
tracking all metric objects in a MetricsBucket.