Skip to content

Using IP in composite aggregate causes array_index_out_of_bounds_exception #30549

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
mvanderlee opened this issue May 12, 2018 · 2 comments
Closed

Comments

@mvanderlee
Copy link

mvanderlee commented May 12, 2018

Elasticsearch version: 6.2 onAWS

Plugins installed: none

JVM version: unknown

OS version: unknown (AWS)

Description of the problem including expected versus actual behavior:

Executing a query with the following aggregate results in and error:

"aggs": {
  "src_ip": {
    "composite": {
      "sources": [{
          "src_ip": {
            "terms": {
              "field": "src_ip",
              "order": "asc"
            }
          }
        }
      ],
      "size": 50
    }
  }
}

Error:

{
    "error": {
        "root_cause": [
            {
                "type": "array_index_out_of_bounds_exception",
                "reason": "16"
            }
        ],
        "type": "array_index_out_of_bounds_exception",
        "reason": "16"
    },
    "status": 500
}

I wonder if the underlying cause is related to #20067

Steps to reproduce:

  1. Create a mapping with an IP field. "src_ip": {"type": "ip"}
  2. Index some data
  3. Execute query with above aggregate

Provide logs (if relevant): None

@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search-aggs

@jimczi
Copy link
Contributor

jimczi commented May 14, 2018

This bug is already fixed for 6.3 by #29370 which now uses the ip formatter to display the bucket key instead of the raw bytes.
Thanks for reporting @MichielVanderlee .

@jimczi jimczi closed this as completed May 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants