# Fielddata cache issue

**URL:** https://discuss.elastic.co/t/fielddata-cache-issue/135770
**Category:** Elasticsearch
**Created:** [June 13, 2018, 4:58pm UTC](https://discuss.elastic.co/t/fielddata-cache-issue/135770 "2018-06-13T16:58:17Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![oo7\_manju](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/oo7_manju/32/12737_2.png) [@oo7\_manju](https://discuss.elastic.co/u/oo7_manju)
#### Post date: [June 13, 2018, 4:58pm UTC](https://discuss.elastic.co/t/fielddata-cache-issue/135770/1 "2018-06-13T16:58:18Z")

</div>

Hi,

We are upgrading Elasticsearch 1.7 to 5.3, observing a weird behaviour with fielddata cache. In one of our index there are keyword datatypes with mapping similar as below  
`"shelf.raw":{ "doc_values":true, "type":"keyword", "eager_global_ordinals": true }`  
During indexation we could observe this field being cached  
`GET /_cat/fielddata?v`

```
`UXi7lSWiTmqXoQYqxd5SGg 10.12.21.233 10.12.21.233 UXi7lSW shelf.raw 4.6kb`

```

But after ForceMerge with maximum segment as 1, then all the fielddata cache size is becoming 0.

```
 `UXi7lSWiTmqXoQYqxd5SGg 10.12.21.233 10.12.21.233 UXi7lSW shelf.raw 0b`

```

After this, even on heavy search load, the size never comes up.

since this happens after reducing the segments, Is it related to "min" settings in "fielddata\_frequency\_filter"

Is this an issue? How to deal with settings for type keyword?

---

<div class="post-metadata">

### Author: ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)
#### Post date: [June 13, 2018, 6:56pm UTC](https://discuss.elastic.co/t/fielddata-cache-issue/135770/2 "2018-06-13T18:56:45Z")

</div>

With doc values you are not using fielddata anymore.

That might explain. But what is the problem with that?

---

<div class="post-metadata">

### Author: ![oo7\_manju](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/oo7_manju/32/12737_2.png) [@oo7\_manju](https://discuss.elastic.co/u/oo7_manju)
#### Post date: [June 13, 2018, 8:06pm UTC](https://discuss.elastic.co/t/fielddata-cache-issue/135770/3 "2018-06-13T20:06:21Z")

</div>

If fielddata is not used, why do it occupies space during index time, which made us to think something not going good.

we are trying to solve Load and performance issues.

With 5.3, CPU utilisation goes high and throws error and high latency. as one of the step, we are checking the cache utilizations

---

<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 11, 2018, 8:06pm UTC](https://discuss.elastic.co/t/fielddata-cache-issue/135770/4 "2018-07-11T20:06:36Z")

</div>

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