rian 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- package/exporter.zipkin.js +7 -2
- package/exporter.zipkin.mjs +7 -2
- package/package.json +1 -1
package/exporter.zipkin.js
CHANGED
@@ -26,8 +26,13 @@ const exporter = (request) => (spans, context) => {
|
|
26
26
|
kind: kind === 'INTERNAL' ? undefined : kind,
|
27
27
|
timestamp: span.start * 1000,
|
28
28
|
duration: span.end ? (span.end - span.start) * 1000 : undefined,
|
29
|
-
localEndpoint: context.localEndpoint
|
30
|
-
|
29
|
+
localEndpoint: context.localEndpoint || {
|
30
|
+
serviceName: span_ctx['service.name'],
|
31
|
+
},
|
32
|
+
tags: flattie.flattie({
|
33
|
+
...context,
|
34
|
+
...span_ctx,
|
35
|
+
}, '.', true),
|
31
36
|
annotations: span.events.map((i) => ({
|
32
37
|
value: `${i.name} :: ${JSON.stringify(i.attributes)}`,
|
33
38
|
timestamp: i.timestamp * 1000,
|
package/exporter.zipkin.mjs
CHANGED
@@ -24,8 +24,13 @@ const exporter = (request) => (spans, context) => {
|
|
24
24
|
kind: kind === 'INTERNAL' ? undefined : kind,
|
25
25
|
timestamp: span.start * 1000,
|
26
26
|
duration: span.end ? (span.end - span.start) * 1000 : undefined,
|
27
|
-
localEndpoint: context.localEndpoint
|
28
|
-
|
27
|
+
localEndpoint: context.localEndpoint || {
|
28
|
+
serviceName: span_ctx['service.name'],
|
29
|
+
},
|
30
|
+
tags: flattie({
|
31
|
+
...context,
|
32
|
+
...span_ctx,
|
33
|
+
}, '.', true),
|
29
34
|
annotations: span.events.map((i) => ({
|
30
35
|
value: `${i.name} :: ${JSON.stringify(i.attributes)}`,
|
31
36
|
timestamp: i.timestamp * 1000,
|