Skip to content

unarchive

Unarchives messages according to the selected archive format into multiple messages within a batch.

# Config fields, showing default values
label: ""
unarchive:
format: "" # No default (required)

When a message is unarchived the new messages replace the original message in the batch. Messages that are selected but fail to unarchive (invalid format) will remain unchanged in the message batch but will be flagged as having failed, allowing you to error handle them.

Metadata

The metadata found on the messages handled by this processor will be copied into the resulting messages. For the unarchive formats that contain file information (tar, zip), a metadata field is also added to each message called archive_filename with the extracted filename.

Fields

format

The unarchiving format to apply.

Type: string

OptionSummary
binaryExtract messages from a binary blob format.
csvAttempt to parse the message as a csv file (header required) and for each row in the file expands its contents into a json object in a new message.
csv:xAttempt to parse the message as a csv file (header required) and for each row in the file expands its contents into a json object in a new message using a custom delimiter. The custom delimiter must be a single character, e.g. the format “csv:\t” would consume a tab delimited file.
json_arrayAttempt to parse a message as a JSON array, and extract each element into its own message.
json_documentsAttempt to parse a message as a stream of concatenated JSON documents. Each parsed document is expanded into a new message.
json_mapAttempt to parse the message as a JSON map and for each element of the map expands its contents into a new message. A metadata field is added to each message called archive_key with the relevant key from the top-level map.
linesExtract the lines of a message each into their own message.
tarExtract messages from a unix standard tape archive.
zipExtract messages from a zip file.