Closed
Description
Today Kibana sends the list of script fields that it may need for convenience, even if it doesn't need any hits. This may be confusing to users sometimes when this causes for instance the script compilation limit to break. While things could be improved on the Kibana side, this issue looks easy to fix in SearchService.parseSource
by just ignoring script fields when size is 0.