# Tagging Queries

**URL:** <https://discuss.elastic.co/t/tagging-queries/45606>\
**Category:** Elasticsearch\
**Created:** [March 28, 2016, 4:22pm UTC](https://discuss.elastic.co/t/tagging-queries/45606 "2016-03-28T16:22:43Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![haperry23](https://avatars.discourse-cdn.com/v4/letter/h/cdc98d/32.png) [@haperry23](https://discuss.elastic.co/u/haperry23)\
**Post date:** [March 28, 2016, 4:22pm UTC](https://discuss.elastic.co/t/tagging-queries/45606/1 "2016-03-28T16:22:43Z")

</div>

Hi, I'm an ES newbie working on a proof-of-concept project with limited time and resources. Is there a way to "tag" queries with unique identifiers which end up in the ES index\_search\_slowlogs? We are performing unit tests on numerous query use cases and are trying to confirm that the query run times reported by our test harness match the run times reported by ES. (If they disagree by a significant amount it would suggest network latency between environments and we can try to measure and troubleshoot that.) We were hoping to include "no-op" parameters in the queries that have no effect on the results or performance but show up the the ES logs so we can readily compare the query run times that get reported between the 2 environments. We thought that the "preference" parameter assigned to unique tracking id's would work but it doesn't seem to get recorded in the ES logs. Is there a straightforward way to do this? Thanks.

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [March 29, 2016, 8:59pm UTC](https://discuss.elastic.co/t/tagging-queries/45606/2 "2016-03-29T20:59:50Z")

</div>

> [@haperry23](#):
>
> Is there a way to "tag" queries with unique identifiers which end up in the ES index\_search\_slowlogs?

I can't immediately think of a way, there isn't anything native to ES to do this anyway.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 5, 2017, 11:04pm UTC](https://discuss.elastic.co/t/tagging-queries/45606/3 "2017-07-05T23:04:15Z")

</div>


