Hello all,
Consider the following mapping:
PUT /test/value/_mapping
{
"properties": {
"value": {
"type": "string",
"index": "analyzed",
"index_analyzer": "standard",
"search_analyzer": "standard",
"fields": {
"integer": {
"type": "integer",
"ignore_malformed": true
},
"double": {
"type": "double",
"ignore_malformed": true
},
"date": {
"type": "date",
"ignore_malformed": true }
}
}
}
}
with simply these documents:
PUT /test/value/1
{
"value": "v1"
}
PUT /test/value/2
{
"value": "2"
}
Writing this aggregation the whole response consists of a
ClassCastException:
POST /test/_search
{
"aggregations": {
"a1": {
"terms": {
"field": "value"
}
},
"a2": {
"max": {
"field": "value"
}
}
}
}
When I'm writing this query I know this is the case but in my application
I'm generating different kinds of aggregations (from which some will give
ClassCastExceptions but I have no easy way of knowing which beforehand).
Is there a way to ignore an aggregation that is invalid and return the
results of the ones which are valid? And similarly, would this work for
nested aggregations?
Thank you, best regards,
--
Nuno Lopes
--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/09b76e9b-e956-4d61-9057-7aa4f655b4bc%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.