# How to send 75 percentile of one field(duration) value to kafka servers

**URL:** https://discuss.elastic.co/t/how-to-send-75-percentile-of-one-field-duration-value-to-kafka-servers/368235
**Category:** Logstash
**Created:** [October 4, 2024, 6:31am UTC](https://discuss.elastic.co/t/how-to-send-75-percentile-of-one-field-duration-value-to-kafka-servers/368235 "2024-10-04T06:31:14Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![upreddy](https://avatars.discourse-cdn.com/v4/letter/u/f04885/32.png) [@upreddy](https://discuss.elastic.co/u/upreddy)
#### Post date: [October 4, 2024, 6:31am UTC](https://discuss.elastic.co/t/how-to-send-75-percentile-of-one-field-duration-value-to-kafka-servers/368235/1 "2024-10-04T06:31:14Z")

</div>

Hi,  
I am trying to send 75 percentile of " **duration**" field(type is number) value to kafka servers by using logstash pipeline. But i did not get idea how to write aggregate filter in logstash. Could you please help me how to write pipeline. Here i am sharing logstash config which i have now.  
input {  
elasticsearch {  
hosts =\> ["XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXx"]  
index =\> "abc\*"  
query =\> '{"query": {  
"bool": {  
"must": ,  
"filter": [

```
  {
      "exists": {
        "field": "duration"
      }
    },
{"range": {
  "@timestamp": {
    "gte": "now-1d/d","lt": "now/d"
  }
}}]}} }'

```

}  
}

filter {

aggregate {  
task\_id =\> "%{duration}"  
code =\> "  
"  
push\_map\_as\_event\_on\_timeout =\> true  
timeout\_task\_id\_field =\> "duration"  
timeout =\> 60  
}  
}
