You can use the processor_drop plugin to drop log fields when collecting logs with Logtail. This topic describes the parameters of the processor_drop plugin and provides configuration examples.
Limits
Text logs and container standard output support only form-based configuration. Other input plugins support only JSON configuration.
Entry point
To use a Logtail plugin to process logs, you can add a plugin configuration when you create or modify a Logtail collection configuration. For more information, see Overview of Logtail plugins for data processing.
Configurations
Logtail 0.16.28 and later supports the processor_drop plugin.
Form configuration
Parameters
Set Processor Type to Drop Field. The following table describes the parameters for this processor.
Parameter
Description
Drop Field
The fields to drop. You can specify multiple fields.
Example
To drop the
aaa1andaaa2fields from a log:Raw log
"aaa1":"value1" "aaa2":"value2" "aaa3":"value3"Logtail plugin configuration

Result
"aaa3":"value3"
JSON configuration
Parameters
Set type to processor_drop. The following table describes the parameters in the detail section.
Parameter
Type
Required
Description
DropKeys
String array
Yes
The fields to drop. You can specify multiple fields.
Example
To drop the aaa1 and aaa2 fields from a log:
Raw log
"aaa1":"value1" "aaa2":"value2" "aaa3":"value3"Logtail plugin configuration
{ "processors":[ { "type":"processor_drop", "detail": { "DropKeys": ["aaa1","aaa2"] } } ] }Result
"aaa3":"value3"
References
Configure a Logtail pipeline using API operations:
GetLogtailPipelineConfig - Get a Logtail pipeline configuration
ListLogtailPipelineConfig - List Logtail pipeline configurations
CreateLogtailPipelineConfig - Create a Logtail pipeline configuration
DeleteLogtailPipelineConfig - Delete a Logtail pipeline configuration
UpdateLogtailPipelineConfig - Update a Logtail pipeline configuration
Configure a processor plugin in the console:
Collect container logs from a Kubernetes cluster using a CRD (stdout/file)