Transform Configuration
Transforms are configured in thetransforms section:
Common Transform Parameters
All transforms support these base configuration options:The type of the transform component.
Array of source or transform IDs to receive events from.
Remap Transform
The most powerful transform - uses Vector Remap Language (VRL) to process events:The VRL program to execute for each event. The
. refers to the event being processed.Path to a file containing the VRL program. Alternative to inline
source.Drop events that cause runtime errors instead of passing them through.
Drop events when the VRL program calls
abort.VRL Examples
Parse JSON logs:Filter Transform
Filter events based on conditions:Condition to evaluate. Events that match pass through.
Type of condition:
vrl, is_log, is_metric, or is_trace.VRL expression that returns a boolean. Required when type is
vrl.Sample Transform
Sample a percentage of events:Keep 1 out of every N events. Rate of 2 = 50%, rate of 10 = 10%.
Field to use for deterministic sampling. Events with the same key value will always be sampled together.
Dedupe Transform
Remove duplicate events:Configuration for matching duplicate events.
Array of field names to use for identifying duplicates.
Number of recent events to cache for comparison.
Reduce Transform
Aggregate multiple events into a single event:Array of field names to group events by.
How to merge field values:
discard, retain, sum, max, min, array, or concat.Milliseconds to wait before flushing a group of events.
Throttle Transform
Limit the rate of events:Maximum number of events to allow per window.
Time window in seconds.
Route Transform
Route events to different downstream components based on conditions:Map of route names to VRL conditions. Each route creates an output that can be referenced as
<transform_id>.<route_name>.Lua Transform
Custom event processing using Lua:Lua transform version: “1” or “2” (recommended).
Lua code to execute. Must define a
process function.Pipeline Example
Chain multiple transforms together:Transform Outputs
Some transforms create multiple outputs:Next Steps
- Sinks - Send transformed data to destinations
- VRL Documentation - Learn Vector Remap Language
- Testing - Test your transform configurations