otel-log-stats
Single-pass OTEL log exploration: discovers attributes and computes top values with severity breakdown (error/warn/info/debug counts).
Single-pass OTEL log exploration: discovers attributes and computes top values with severity breakdown (error/warn/info/debug counts). Skips rows without a body column.
Recommended columns for OTel logs: attributes, resource.attributes
(the default attribute locations in the Berserk OTel log mapping).
The severity parameter defaults to severity_number if not specified.
Output: Two tables. Table 1 (Attributes): AttributePath, Type, Cardinality, Frequency Table 2 (Values): AttributePath, Value, Total, ErrorCount, WarnCount, InfoCount, DebugCount, HasMore
Syntax
otel-log-stats attributes, resource.attributesAnalyze OTel log attributes (severity defaults to severity_number)
Syntax
otel-log-stats col1, col2 severity=sev_colAnalyze log attributes with explicit severity column
Syntax
otel-log-stats col severity=sev_col top_attrs=20 top_values=15Analyze with custom limits
Examples
Example 1 — Analyze OTel log attributes and resource attributes
Logs
| otel-log-stats attributes, resource.attributesResult table 1:
| AttributePath (string) | Type (string) | Cardinality (long) | Frequency (real) |
|---|
Result table 2:
| AttributePath (string) | Value (dynamic) | Total (long) | ErrorCount (long) | WarnCount (long) | InfoCount (long) | DebugCount (long) | HasMore (bool) |
|---|
Example 2 — Analyze with custom limits
Logs
| otel-log-stats attributes, resource.attributes top_attrs = 10 top_values = 5Result table 1:
| AttributePath (string) | Type (string) | Cardinality (long) | Frequency (real) |
|---|
Result table 2:
| AttributePath (string) | Value (dynamic) | Total (long) | ErrorCount (long) | WarnCount (long) | InfoCount (long) | DebugCount (long) | HasMore (bool) |
|---|
Example 3 — Analyze with explicit severity column
Logs
| otel-log-stats attributes severity = my_severity_colResult table 1:
| AttributePath (string) | Type (string) | Cardinality (long) | Frequency (real) |
|---|
Result table 2:
| AttributePath (string) | Value (dynamic) | Total (long) | ErrorCount (long) | WarnCount (long) | InfoCount (long) | DebugCount (long) | HasMore (bool) |
|---|
Related
fieldstats
Analyzes dynamic column values to discover field paths and their statistics, returning a table with AttributePath, Type, Cardinality, Frequency, Hint, and HintExhaustive columns.
annotate
Adds type annotations to dynamic columns, enabling forward-flow type inference and zero-copy access when runtime type matches annotation.