The Javascript implementation of the BasicTracer referrence implementation
npm install --save basictracer
var tracer = require('basictracer')
tracer.setRecorder(function record(span) {
log(span)
})
var span = tracer.startSpan('operationName')
span.tag('key', 'value')
span.log('read', {duration: 1000})
span.finish()
See tests for more example.
type Span {
operationName: String
startTime: Number
duration: Number
tags: [Object]
logs: [Array]
traceId: Long
spanId: Long
parentId: String
sampled: Boolean
baggage: Object
}
Long
type represent by long.js
MIT