func (r *Registry) NewMetricSink(logger logger.Logger,
	processorConfiguration *processor.Configuration,
	kind string,
	name string,
	metricSinkConfiguration *platformconfig.MetricSink,
	metricProvider MetricProvider) (MetricSink, error) {
	registree, err := r.Get(kind)
	if err != nil {
		return nil, err
	}
	return registree.(Creator).Create(logger,
		processorConfiguration,
		name,
		metricSinkConfiguration,
		metricProvider)
}
NewMetricSink creates a new metric sink
package metricsink
import (
	"github.com/nuclio/nuclio/pkg/platformconfig"
	"github.com/nuclio/nuclio/pkg/processor"
	"github.com/nuclio/nuclio/pkg/registry"
	"github.com/nuclio/logger"
)
type Creator interface {
	Create(logger.Logger, *processor.Configuration, string, *platformconfig.MetricSink, MetricProvider) (MetricSink, error)
}
type Registry struct {
	registry.Registry
}
var RegistrySingleton = Registry{
	Registry: *registry.NewRegistry("metricsink"),
}