I have an index with over 9,000,000 docs.
I have defined my own mapping and everything went fine.
The only problem is that I forgot to enable the _size field and now I need it to localize document with a large size.
From the documentation I found that it's just fine to use the PUT mapping API with these parameters:
{
"my_index": {
"_size": {
"enabled": true
}
}
}
I am a little worried making changes to mapping beacuse the last time that I have updated the settings with a new analyzer the service was having problem due to shard relocation and everything got stuck.
The mappings will be merged OK and the _size field will be enabled for all your documents of type my_index.
Note that if you want to store the _size (in addition to just index its value), you also need to add "store": "yes" in your _size mapping.
Unfortunately, you'll need to re-index your data in order for the _size field to be properly indexed.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With