Beispiel #1
0
func setupMonitoring(router *trafficcontroller.Router, config *Config, logger *gosteno.Logger) {
	cr := collectorregistrar.NewCollectorRegistrar(config.MbusClient, logger)
	err := cr.RegisterWithCollector(router.Component)
	if err != nil {
		panic(err)
	}

	go func() {
		err := router.StartMonitoringEndpoints()
		if err != nil {
			panic(err)
		}
	}()
}
Beispiel #2
0
func startIncomingRouter(router *trafficcontroller.Router, logger *gosteno.Logger) {
	go router.Start(logger)
}