Rename Fields
CAUTION
This transform has been deprecated in favor of the remap
transform, which enables you to use Vector Remap Language (VRL for short) to
create transform logic of any degree of complexity. The examples below show how you can use VRL to
replace this transform's functionality.
.new_name = del(.old_name)
Configuration Options
Required Options
inputs(required)
A list of upstream source or transform
IDs. Wildcards (*
) are supported.
See configuration for more info.
Type | Syntax | Default | Example |
---|---|---|---|
array | literal | ["my-source-or-transform-id","prefix-*"] |
fields(required)
A table of old-key/new-key pairs representing the keys to be moved in the event.
Type | Syntax | Default | Example |
---|---|---|---|
hash | [{"old_field_name":"new_field_name","parent":{"old_child_name":"parent.new_child_name"}}] |
type(required)
The component type. This is a required field for all components and tells Vector which component to use.
Type | Syntax | Default | Example |
---|---|---|---|
string | literal | ["rename_fields"] |
Advanced Options
drop_empty(optional)
If set to true
, after renaming fields, remove any parent objects of the old field that are now empty.
Type | Syntax | Default | Example |
---|---|---|---|
bool |
How it Works
Conflicts
State
This component is stateless, meaning its behavior is consistent across each input.