Edge Delta Copy Field Processor
4 minute read
Overview
The copy field processor copies an existing field’s value. It can create a new field for the copied value, or it can overwrite an existing field with the new value. You can set the processor to apply only to a specific data item type, such as logs, metrics or traces, and you can create a condition that must be met by the data item for the processor to operate.
Configuration
In this example, the service_name attribute is copied and an attribute called service_name is created. It does this only for log data items, and only for data items whose resource["service.name"]
value is frontend-proxy
.

The Final option stops subsequent processors in the multiprocessor node from executing if the conditions are met for this processor to operate. Processors in downstream nodes will still operate as usual.
- name: Multi Processor
type: sequence
processors:
- type: ottl_transform
metadata: '{"id":"jwxzE8oVhwMd_VCK4l12H","type":"copy-field","name":"Copy Field"}'
condition: resource["service.name"] == "frontend-proxy"
data_types:
- log
statements: set(attributes["service_name"], resource["service.name"])
Options
Select a telemetry type
You can specify, log
, metric
, trace
or all
. It is specified using the interface, which generates a YAML list item for you under the data_types
parameter. This defines the data item types against which the processor must operate. If data_types is not specified, the default value is all
. It is optional.
It is defined in YAML as follows:
- name: multiprocessor
type: sequence
processors:
- type: <processor type>
data_types:
- log
condition
The condition
parameter contains a conditional phrase of an OTTL statement. It restricts operation of the processor to only data items where the condition is met. Those data items that do not match the condition are passed without processing. You configure it in the interface and an OTTL condition is generated. It is optional. You can select one of the following operators:
Operator | Name | Description | Example |
---|---|---|---|
== |
Equal to | Returns true if both values are exactly the same |
attributes["status"] == "OK" |
!= |
Not equal to | Returns true if the values are not the same |
attributes["level"] != "debug" |
> |
Greater than | Returns true if the left value is greater than the right |
attributes["duration_ms"] > 1000 |
>= |
Greater than or equal | Returns true if the left value is greater than or equal to the right |
attributes["score"] >= 90 |
< |
Less than | Returns true if the left value is less than the right |
attributes["load"] < 0.75 |
<= |
Less than or equal | Returns true if the left value is less than or equal to the right |
attributes["retries"] <= 3 |
matches |
Regex match | Returns true if the string matches a regular expression |
isMatch(attributes["name"], ".*\\.name$" |
It is defined in YAML as follows:
- name: _multiprocessor
type: sequence
processors:
- type: <processor type>
condition: attributes["request"]["path"] == "/json/view"
statements
The statements
parameter contains the OTTL statement used to copy an existing field. It is generated by the tool as you configure interface options.
Copy From
Specify the field that you want to copy.
Copy To
Specify the field path for the destination where you want the copied item.
Final
Determines whether successfully processed data items should continue through the remaining processors in the same processor stack. If final
is set to true
, data items output by this processor are not passed to subsequent processors within the node—they are instead emitted to downstream nodes in the pipeline (e.g., a destination). Failed items are always passed to the next processor, regardless of this setting.
The UI provides a slider to configure this setting. The default is false. It is defined in YAML as follows:
- name: multiprocessor
type: sequence
processors:
- type: <processor type>
final: true
See Also
- For an overview and to understand processor sequence flow, see Processors Overview
- To learn how to configure a processor, see Configure a Processor.
- For optimization strategies, see Best Practices for Edge Delta Processors.
- If you’re new to pipelines, start with the Pipeline Quickstart Overview or learn how to Configure a Pipeline.
- Looking to understand how processors interact with sources and destinations? Visit the Pipeline Overview.