keep
Remove all fields from the input stream except those that are specified. Use this processor to prune the input stream, keeping only the fields of interest.
Note:
The time field must be specified
explicitly in order to keep it; otherwise you end up with timeless
points.
keep fieldName1, fieldName2,...fieldNameN
Parameter | Description | Required? |
---|---|---|
fieldnameN |
The fields to propagate from input to output | At least one |
Example: Remove all fields except the a field, then log the remaining data points
emit -hz 10 -limit 10
| put a = 1, b = 2
| keep a
| view text