Merge pull request #2265 from jodh-intel/unbreak-tracing-test

tracing: Unbreak tracing test
This commit is contained in:
GabyCT
2019-11-25 13:16:01 -06:00
committed by GitHub

View File

@@ -44,6 +44,14 @@ func CreateTracer(name string) (opentracing.Tracer, error) {
Type: "const",
Param: 1,
},
// Ensure that Jaeger logs each span.
// This is essential as it is used by:
//
// https: //github.com/kata-containers/tests/blob/master/tracing/tracing-test.sh
Reporter: &config.ReporterConfig{
LogSpans: tracing,
},
}
logger := traceLogger{}
@@ -92,6 +100,8 @@ func Trace(parent context.Context, name string) (opentracing.Span, context.Conte
// are still created - but the tracer used is a NOP. Therefore, only
// display the message when tracing is really enabled.
if tracing {
// This log message is *essential*: it is used by:
// https: //github.com/kata-containers/tests/blob/master/tracing/tracing-test.sh
kataUtilsLogger.Debugf("created span %v", span)
}