I make some visualization in Kibana and i'm not sure to understand the difference between "Metric: Count" and "Term" for a sub-aggregation in the "Order By" part.
I get different results if I try one or the other. But I can't explain.
For me the "Metric: Count" counts the number of documents returned. But I can't explain the other...
Yes, the "Order By" is affecting your results because of the Size field below that. So if you order by "Metric: Count" you get the top "size" results back based on the Count.
But if you can that to order by the Term (uses the field of that sub aggregation) then you get the top "size" results back of that term.
May be it's a translation issue but I'm not sure to understand.
"Metric: Count" represent the number of documents returns ? "Term" represent the number of documents matching some criteria ? For exemple "field:storm*"
In this visualization the Y-Axis is showing the Count of documents
and the x-axis is showing the top 20 terms in the name field.
And Order By: metric: Count shows Chrome first in the chart because it has the highest Count.
Or I can leave the Y-Axis on Max bytes, and just change the Order By to Term. So now it's showing me the top 20 terms in order, and the Max bytes of each of them. Chrome starts with C and is still in that list, but Firefox isn't in the top 20 of the name field. So yes, it makes it return different data. If there were less than 20 terms for this field I think you would get the same results but only in a different order.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.