Created
December 7, 2017 20:53
-
-
Save DanielMSchmidt/4c95fb1df034700a2927525dc296d9ed to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import zipkin from "zipkin"; | |
import { HttpLogger } from "zipkin-transport-http"; | |
const tracer = new zipkin.Tracer({ | |
ctxImpl: new zipkin.ExplicitContext(), | |
recorder: new zipkin.BatchRecorder({ | |
logger: new HttpLogger({ | |
endpoint: 'http://localhost:9411/api/v2/spans', | |
jsonEncoder: zipkin.jsonEncoder.JSON_V2, | |
fetch | |
}) | |
}), | |
sampler: new zipkin.sampler.CountingSampler(1), | |
localServiceName: "frontend" | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment