mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-07 13:38:49 +00:00
This commit fixes several NPEs caused by implicitly performing a get request for a document that exists with its _source disabled and then trying to access the source. Instead of causing an NPE the following queries will throw an exception with a "source disabled" message (similar behavior as if the document does not exist).: - GeoShape query for pre-indexed shape (throws IllegalArgumentException) - Percolate query for an existing document (throws IllegalArgumentException) A Terms query with a lookup will ignore the document if the source does not exist (same as if the document does not exist). GET and HEAD requests for the document _source will return a 404 if the source is disabled (even if the document exists).