smiklosovic opened a new pull request #4057:
URL: https://github.com/apache/zeppelin/pull/4057


   ### What is this PR for?
   This PR fixes issus for search command in Elasticsearch as it is not working 
now. This is rather a serious problem as right now, ES interpreter is more or 
less useless when one can not search in it so it would be awesome if it is 
merged as not doing so renders that plugin useless. 
   
   The problem is that in the past, there was this in the response from a 
server on search:
   
   ```
   {
       "took": 1,
       "timed_out": false,
       "_shards": {
           "total": 1,
           "successful": 1,
           "skipped": 0,
           "failed": 0
       },
       "hits": {
           "total": 1
        },
   /// other fields omitted for brevity
   ```
   
   but now it returns:
   
   ```
   {
       "took": 1,
       "timed_out": false,
       "_shards": {
           "total": 1,
           "successful": 1,
           "skipped": 0,
           "failed": 0
       },
       "hits": {
           "total": {
               "value": 1,
               "relation": "eq"
           },
   /// other fields omitted for brevity
   ```
   This changed behaviour seems to be introduced in recent ES versions 7.x, I 
do not have any capability to check how far into the past this issue is 
present, I have done it in such a way that it is backward-compatible with older 
versions too.
   
   ### What type of PR is it?
   Bug Fix.
   
   ### What is the Jira issue?
   ZEPPELIN-4843
   
   ### How should this be tested?
   * I have run unit tests in Java for ES interpreter, they all worked.
   
   ### Questions:
   * Does the licenses files need update? - no
   * Is there breaking changes for older versions? - no, the older version is 
still supported, the solution works as it was but it fallbacks to new way of 
doing things for more recent ES versions.
   * Does this needs documentation? - no
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to