I have a problem with Java API and aggregations result
Serializer (jackson) produce this error:
No serializer found for class org.elasticsearch.common.text.StringText and
no properties discovered to create BeanSerializer
for this query :
- {
-
"size": 0, -
"aggregations": { -
"agg": { -
"global": {}, -
"aggregations": { -
"dim-1": { -
"terms": { -
"field": "field-1" -
}, -
"aggregations": { -
"dim-2": { -
"terms": { -
"field": "field-2" -
}, -
"aggregations": { -
"myStats": { -
"stats": { -
"field": "statsField" -
} -
} -
} -
} -
} -
} -
} -
} -
} - }
with this response :
- {
- "took":15932,
- "timed_out":false,
- "_shards":{
-
"total":2, -
"successful":2, -
"failed":0 - },
- "hits":{
-
"total":38376901, -
"max_score":0, -
"hits":[ -
] - },
- "aggregations":{
-
"agg":{ -
"doc_count":38376901, -
"dim-1":{ -
"buckets":[ -
{ -
"key":27380, -
"doc_count":311352, -
"dim-2":{ -
"buckets":[ -
{ -
"key":1, -
"doc_count":275581, -
"statsField":{ -
"count":275581, -
"min":245, -
"max":1295001, -
"avg":111170.57729999075, -
"sum":30636498862.908752 -
} -
}, -
{ -
"key":2, -
"doc_count":35771, -
"statsField":{ -
"count":35771, -
"min":300, -
"max":2070000, -
"avg":288086.52814757434, -
"sum":10305143198.366882 -
} -
} -
] -
} -
}, -
{ -
"key":1595, -
"doc_count":269090, -
"dim-2":{ -
"buckets":[ -
{ -
"key":1, -
"doc_count":221705, -
"statsField":{ -
"count":221705, -
"min":180, -
"max":3450000, -
"avg":69082.0294308078, -
"sum":15315831334.957245 -
} -
}, -
{ -
"key":2, -
"doc_count":47385, -
"statsField":{ -
"count":47385, -
"min":250, -
"max":6000000, -
"avg":298778.0619758563, -
"sum":14157598466.725952 -
} -
} -
] -
} -
} -
] -
} -
} - }
- }
How can I successfully serialize aggregations result ?
--
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 elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/61d79a3a-6fcd-458a-8e24-76e25ac4810d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.