Skip to content

Using IP in composite aggregate causes array_index_out_of_bounds_exception #30549

Closed
@mvanderlee

Description

@mvanderlee

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions