DBAtlas · Database operations atlas

document_source_missing_exception: Document source is missing

Elasticsearch

What does it mean?

The operation needs the document's _source field, but it is not stored. An operation that requires _source (e.g. partial update, fetching source) was attempted on an index with source disabled.

Why does it happen?

The index mapping sets _source: {enabled: false}; since the document's original JSON is not stored, partial updates, reindex and queries that return _source cannot work. Configurations that disable source to save space cause this problem.

How to fix it

Operations that need _source require source to be enabled in the mapping. When creating a new index, leave _source enabled (it is enabled by default). If _source is disabled on an existing index, reindex the full document instead of updating it (overwrite with the index API). To save space, consider _source filtering (includes/excludes) or synthetic _source instead of disabling source entirely.

Open in DBAtlas →

More from this engine