Skip to main content

What "traces as logs" (the log span creation option) publishes for a span.

Properties (5)

Property Type Default Required Description
enabled⚓︎ boolean false x

If true, the span is published as a log entry when it is enabled. Leave it out to keep what a less specific place (the span's options, the defaults) says.

includeEvents⚓︎ boolean false x

If true, the log entries published for the span also carry its events - among them the exceptions recorded on it, with their type, message and stack trace, which can make the entries long.

includeResourceAttributes⚓︎ boolean false x

If true, the log entries published for the span also carry the resource attributes, as resource in the details object that follows the span attributes. They are the same for every span of a process, so they are left out by default.

onDisabledSpans⚓︎ boolean false x

If true, the span is published as a log entry when it is disabled. There is no span behind such an entry: it is logged at the level the span is configured with, with ids of its own (under the trace and parent it would have had), the attributes it would have carried, and insightsSpanDisabled: true among them.