Home > Blockchain >  Drop Processor on APM-Elastic
Drop Processor on APM-Elastic

Time:07-23

I am using Elastic APM, but want to drop some data based on service.environment, but seems it not to be working. below is the code under ingest pipeline

[
  {
    "drop": {
      "if": "'service.environment' == 'ct1'",
      "description": "Drop documents that contain 'service.environment' == ct1"
    }
  }
]

CodePudding user response:

The condition needs to be

[
  {
    "drop": {
      "if": "ctx.service.environment == 'ct1'",
      "description": "Drop documents that contain 'service.environment' == ct1"
    }
  }
]
 
  • Related