The way Elasticsearch deals with control heap memory when indexing documents

14 Views Asked by At

I have a question about objects genereated when the document is indexed.

All objects based on jvm are stored in heap and will be reclaimed by GC unless they are still referenced by other objects or method. (called LIVE OBJECT)

When the document is indexed, we POST/PUT data as a format of '_source' (json or NDJSON). At that time, how will fields of json be splitted as objects?

For example, let's say {"name": "Tom", "age": 26, "position": "developer"} is _source of document.

If Then, 2 objects (except "age" value because it's not a String type.) are stored in Eden Region? Or, whole _source will be regarded as one object?

0

There are 0 best solutions below