utilize newly available easier creation of RPC Server span
Bas van Beek
7 years ago
42 | 42 |
if err != nil {
|
43 | 43 |
logger.Log("err", err)
|
44 | 44 |
}
|
45 | |
if wireContext != nil {
|
46 | |
span = tracer.StartSpan(operationName, ext.RPCServerOption(wireContext))
|
47 | |
} else {
|
48 | |
span = tracer.StartSpan(operationName)
|
49 | |
}
|
|
45 |
span = tracer.StartSpan(operationName, ext.RPCServerOption(wireContext))
|
50 | 46 |
return opentracing.ContextWithSpan(ctx, span)
|
51 | 47 |
}
|
52 | 48 |
}
|
64 | 64 |
if err != nil {
|
65 | 65 |
logger.Log("err", err)
|
66 | 66 |
}
|
67 | |
if wireContext != nil {
|
68 | |
span = tracer.StartSpan(operationName, ext.RPCServerOption(wireContext))
|
69 | |
} else {
|
70 | |
span = tracer.StartSpan(operationName)
|
71 | |
}
|
|
67 |
span = tracer.StartSpan(operationName, ext.RPCServerOption(wireContext))
|
72 | 68 |
return opentracing.ContextWithSpan(ctx, span)
|
73 | 69 |
}
|
74 | 70 |
}
|