Skip to main content
This information is for Chronosphere Telemetry Pipeline, which is a standalone product separate from Chronosphere Observability Platform.
The encode CSV processing rule transforms log data from JSON to CSV format. The resulting output includes both the original JSON data and a string of comma-separated values assigned to a key you specify.

Configuration parameters

Use the parameters in this section to configure the . The Telemetry Pipeline web interface uses the items in the Name column to describe these parameters. Pipeline configuration files use the items in the Key column as YAML keys.

Examples

Using the encode CSV rule lets you turn JSON data into comma-separated values that can be fed into databases and spreadsheet software.

Array of strings

If your JSON data is an array of strings, don’t use the Header parameter. For example, given this sample JSON data:
A processing rule with the Source key value ingredients and the Destination key value encoded_csv returns the following result:
This rule retained the original ingredients array and created a new key called encoded_csv to store the converted comma-separated values.

Key/value pairs

If your JSON data is an object that contains key/value pairs, you must use the Header parameter. For example, given this sample website log data:
A processing rule with the Source key value log, the Destination key value encoded_csv, and the Header value timestamp,user_id,action,page_id returns the following result:
This rule retained the original log object and created a new key called encoded_csv to store the converted comma-separated values. Additionally, the first instance of encoded_csv contains a header row, which is also separated by commas. For a processing rule with the opposite effect, see decode CSV.