How to avoid duplicate values in ealstic search 5.6.4

want to delete the duplicates the below code is correct

the below code is written in the logstash file under config file.
file type is conf file.

output {

elasticsearch {
hosts => ["localhost:9200"]
manage_template => false
index => "test" }
stdout { codec => rubydebug }

document_id => "%{[@metadata][_mrdno]}"
}

want to remove the duplicates of mrdno column.

please let me know