Comments (6)
sounds like a bug. However, we have a use case to return SpanContext with empty traceID but other fields set which is used for starting debug traces.
from jaeger-client-node.
Opened opentracing/specification#104
from jaeger-client-node.
We've had a problem which I think is related (had to debug though).
Our code looks like this:
const parentContext = tracer.extract(
FORMAT_HTTP_HEADERS,
headers,
)
const spanOptions: opentracing.SpanOptions = {
startTime: startTime.getTime(),
tags: {
// ...
},
}
// Adding this causes problems
if (parentContext != null) {
spanOptions.references = [opentracing.followsFrom(parentContext)]
}
// edited comment to add this line
const span = tracer.startSpan(OPERATION_NAME, spanOptions)
We get the following error:
Failed to append spans in reporter: error converting span to Thrift: spanId: missing required field "spanId" with id 4 on SpanRef
We've needed to change it to the following:
if (parentContext != null) {
if ((parentContext as any)._spanIdStr != null) {
spanOptions.references = [opentracing.followsFrom(parentContext)]
}
}
Curiously we don't get the same error with spanOptions.childOf
. Should I raise a separate issue for this?
from jaeger-client-node.
.references
are not supposed to be mutated after creating the span.
from jaeger-client-node.
.references
are not supposed to be mutated after creating the span.
It isn't mutated after creating the span. See my edited comment above. The spanOptions
are mutated before creating the span.
from jaeger-client-node.
@ThomWright it's odd, looks like a bug.
from jaeger-client-node.
Related Issues (20)
- Proposal: Convert thrift IDL files to standard JavaScript imports during build HOT 2
- Outdated xorshift dependency causes deprecation warning
- Incorrect error message "The sampling rate must be less than 0.0 and greater than 1.0"
- Debug-only SpanContext cannot be used with Follows-From HOT 3
- ref.type is not a function while using follows_from HOT 3
- Inconsistency with jaeger-agent probabilistic sampling rate number range HOT 6
- Not support report GRPC proto to agent?
- how to pass context in grpc ?
- sampler.param is serialized into boolean
- NoopTracer doesn't implement jaeger tracer functions registerInjector/registerExtractor
- how to pass the endpoint
- Improve http sender TLS documentation
- Link to tutorial repository opentracing-tutorial HOT 2
- Migrate CI to GitHub Actions HOT 3
- Jaeger client node can't report span with https protocol via AWS API Gateway. HOT 1
- How to configure two different collectors in single nodejs application HOT 1
- HTTP errors on flush are not reported
- ConfigurationEnv doesn't allow falsy values HOT 1
- Converting circular structure to JSON HOT 1
- Cannot configure samplingPath for remote sampling in trace configuration
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jaeger-client-node.