Better build tracing
package main
import (
- "io"
"net/url"
"os"
"path/filepath"
"github.com/hellofresh/janus/pkg/config"
- tracerfactory "github.com/hellofresh/janus/pkg/opentracing"
"github.com/hellofresh/janus/pkg/store"
"github.com/hellofresh/stats-go"
"github.com/hellofresh/stats-go/bucket"
"github.com/hellofresh/stats-go/client"
"github.com/hellofresh/stats-go/hooks"
- "github.com/opentracing/opentracing-go"
log "github.com/sirupsen/logrus"
"gopkg.in/mgo.v2"
)
@@ -46,19 +43,6 @@ func initLog() {
}
}
-// initializes distributed tracing
-func initDistributedTracing() io.Closer {
- log.Debug("Initializing distributed tracing")
- tracer, closer, err := tracerfactory.Build(globalConfig.Tracing)
- if err != nil {
- log.WithError(err).Fatal("Could not build a tracer")
- }
-
- opentracing.SetGlobalTracer(tracer)
-
- return closer
-}
-
func initStatsd() {
// FIXME: this causes application hang because we're in the locked log already
//statsLog.SetHandler(func(msg string, fields map[string]interface{}, err error) {
