# Can't search by custom response headers

**URL:** https://discuss.elastic.co/t/cant-search-by-custom-response-headers/292217
**Category:** APM
**Tags:** server
**Created:** [December 16, 2021, 7:42pm UTC](https://discuss.elastic.co/t/cant-search-by-custom-response-headers/292217 "2021-12-16T19:42:41Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![ufanautas](https://avatars.discourse-cdn.com/v4/letter/u/a87d85/32.png) [@ufanautas](https://discuss.elastic.co/u/ufanautas)
#### Post date: [December 16, 2021, 7:42pm UTC](https://discuss.elastic.co/t/cant-search-by-custom-response-headers/292217/1 "2021-12-16T19:42:41Z")

</div>

**Kibana version** : 7.15.1

**Elasticsearch version** : 7.15.1

**APM Server version** :7.15.1

**APM Agent language and version** : 1.26.0 Java

Hello!

I'm facing an issue that I can't make serachable transcations in APM UI. for http.response.headers that are in metadata

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/6/3/63701001c97944713bae0785a58431a7abc5ac33.png)

Specificly X-Transcation-ID

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/f/5/f585867ff4a4657ab6236e22267444554c503b14.png)

I have set up setup in APM server:

setup.template.overwrite: true

setup.template.append\_fields:

- name: http.response.headers

Seems that it doesn't work

---

<div class="post-metadata">

### Author: ![axw](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/axw/32/28197_2.png) [@axw](https://discuss.elastic.co/u/axw)
#### Post date: [December 17, 2021, 12:29am UTC](https://discuss.elastic.co/t/cant-search-by-custom-response-headers/292217/2 "2021-12-17T00:29:35Z")

</div>

@ufanautas welcome to the forum!

Did you make the config change before or after you started ingesting data? Existing indices won't be affected, so you would have to perform a manual rollover on your APM index aliases (`apm-7.15.1-transaction`, `apm-7.15.1-span`, ...). See [Rollover API | Elasticsearch Guide [7.16] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-rollover-index.html) for how to do that.

---

<div class="post-metadata">

### Author: ![ufanautas](https://avatars.discourse-cdn.com/v4/letter/u/a87d85/32.png) [@ufanautas](https://discuss.elastic.co/u/ufanautas)
#### Post date: [December 17, 2021, 2:35pm UTC](https://discuss.elastic.co/t/cant-search-by-custom-response-headers/292217/3 "2021-12-17T14:35:53Z")

</div>

@axw As I use Docker, I just completely wipe out elastic volume's and built APM image (as i'm copying config inside of it in docker file) Seems nothing to change. only Elasticsearch has persistent volume configured. So a bit confused. Will try this. Will write if it work thanks!

---

<div class="post-metadata">

### Author: ![ufanautas](https://avatars.discourse-cdn.com/v4/letter/u/a87d85/32.png) [@ufanautas](https://discuss.elastic.co/u/ufanautas)
#### Post date: [December 17, 2021, 3:13pm UTC](https://discuss.elastic.co/t/cant-search-by-custom-response-headers/292217/4 "2021-12-17T15:13:22Z")

</div>

> [@axw](#):
>
> apm-7.15.1-span

It worked. But APM search bar seems to still use the old ones? The mappings updated, created a new index with it. But it still not searchable

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/2/f/2f69f89f152739caf4a8107b01014b0b624f1c51.png)

---

<div class="post-metadata">

### Author: ![ufanautas](https://avatars.discourse-cdn.com/v4/letter/u/a87d85/32.png) [@ufanautas](https://discuss.elastic.co/u/ufanautas)
#### Post date: [December 17, 2021, 3:48pm UTC](https://discuss.elastic.co/t/cant-search-by-custom-response-headers/292217/5 "2021-12-17T15:48:41Z")

</div>

IT worked had to target to create new index with \_rollover/transcation001, but now it seems that the APM server doesn't get anything from its agent.

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/9/0/902bd2b501f673a6a240e7f984a0c39cb09ddf33.png)

---

<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: [January 7, 2022, 11:49am UTC](https://discuss.elastic.co/t/cant-search-by-custom-response-headers/292217/6 "2022-01-07T11:49:25Z")

</div>

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.
