agent/metrics/metrics_factory.go
func NewMetricsClient(api APIType, registry *prometheus.Registry) MetricsClient {
	switch api {
	case DockerAPI:
		return NewGenericMetricsClient(DockerSubsystem, registry)
	case TaskEngine:
		return NewGenericMetricsClient(TaskEngineSubsystem, registry)
	case StateManager:
		return NewGenericMetricsClient(StateManagerSubsystem, registry)
	case ECSClient:
		return NewGenericMetricsClient(ECSClientSubsystem, registry)
	default:
		seelog.Error("Unmanaged MetricsClient cannot be created.")
		return nil
	}
}
func NewMetricsClient(api APIType, registry *prometheus.Registry) MetricsClient {
	switch api {
	case DockerAPI:
		return NewGenericMetricsClient(DockerSubsystem, registry)
	case TaskEngine:
		return NewGenericMetricsClient(TaskEngineSubsystem, registry)
	case StateManager:
		return NewGenericMetricsClient(StateManagerSubsystem, registry)
	case ECSClient:
		return NewGenericMetricsClient(ECSClientSubsystem, registry)
	default:
		seelog.Error("Unmanaged MetricsClient cannot be created.")
		return nil
	}
}
// A factory method that enables various MetricsClients to be created.