Developer Reference: This page is designed as a practical guide for implementing data transformation pipelines through filters.
What are Filters?
Filters define how to extract and transform data from raw events into a standardized format that can be:- Analyzed by correlation rules
- Searched in Log Explorer
- Visualized in dashboards
- Stored efficiently
Purpose
- Parse raw log formats (JSON, CSV, key-value, free text)
- Extract relevant fields from unstructured data
- Normalize field names across data sources
- Enrich data with additional context
- Transform data types for proper analysis
Filter Structure
Filter Steps Reference
Parsing Steps
| Step | Purpose | Use Case |
|---|---|---|
json | Parse JSON data | Structured logs from applications |
grok | Pattern-based parsing | Unstructured text logs (Apache, Syslog) |
kv | Key-value pair parsing | Simple formatted logs |
csv | CSV data parsing | Comma-separated log formats |
Transformation Steps
| Step | Purpose | Use Case |
|---|---|---|
rename | Rename fields | Standardize field names |
cast | Convert data types | Ensure proper types for analysis |
reformat | Reformat values | Timestamp conversion, string formatting |
trim | Remove characters | Clean up parsed data |
Enrichment Steps
| Step | Purpose | Use Case |
|---|---|---|
add | Add new fields | Add metadata, computed values |
dynamic | Call external plugins | Geolocation, threat intelligence |
expand | Expand nested data | Flatten complex structures |
Cleanup Steps
| Step | Purpose | Use Case |
|---|---|---|
delete | Remove fields | Remove unnecessary data |
Quick Start Example
Here’s a complete filter for Apache access logs:Development Workflow
1
Identify Data Source
Determine what log source you need to process
2
Analyze Raw Format
Examine sample raw events to understand structure
3
Create Filter File
Start with basic parsing steps
4
Add Transformation
Normalize fields and data types
5
Enrich Data
Add geolocation, classifications
6
Test Filter
Deploy and test with sample data
7
Optimize
Remove unnecessary fields, improve performance
Best Practices
Standardize Field Names
- Use consistent naming across all filters
- Follow UTMStack field mapping conventions
- Common fields:
origin.ip,target.ip,deviceTime,action,actionResult
- Delete fields not needed for analysis
- Reduces storage requirements
- Improves query performance
- Use conditional steps with
whereclauses - Test with incomplete/malformed data
- Provide sensible defaults
- Apply heavy operations conditionally
- Use efficient parsing methods
- Delete unnecessary fields early in pipeline
- Comment complex patterns
- Explain transformation logic
- Note data source requirements
Common Patterns
Pattern 1: Web Server Logs
Pattern 2: Syslog Parsing
Pattern 3: JSON with Nested Data
Troubleshooting
Filter Not Processing
Check: Event has correctdataType field matching filter configuration