Merge pull request #1020 from vector-im/dbkr/rageshake_processor_event_name

Add the event name to the rageshake span processor export
This commit is contained in:
David Baker
2023-04-21 10:24:31 +01:00
committed by GitHub

View File

@@ -98,7 +98,11 @@ export class RageshakeSpanProcessor implements SpanProcessor {
tags: dumpAttributes(span.attributes),
logs: span.events.map((event) => ({
timestamp: hrTimeToMicroseconds(event.time),
fields: dumpAttributes(event.attributes ?? {}),
// The name of the event is in the "event" field, aparently.
fields: [
...dumpAttributes(event.attributes ?? {}),
{ key: "event", type: "string", value: event.name },
],
})),
};
}),