Closed
Description
Having a larger number of mapped fields consumes quite a bit of heap memory. TextFieldMapper holds onto its builder object, which results in a simple field definition to easily hold onto 7KB of heap memory. This means that on a small node (1GB heap), 20k fields (e.g. 20 indices with 1000 fields each) can result in 150MB of memory being used purely for the mappings.
Relates #63269