Hello, I am Youngmin.
I have 100,000,000 data in my elasticsearch.
Because of the large data, there are too many time visualizing the count data in Time Graph.
So, I push the aggregation data in my elasticsearch.
It is JSON type.
And I visualize the data.
Date histogram is 'aggregations.by_day_hostname.buckets.key_as_string'
Metrics is 'aggregations.by_day_hostname.buckets.group_by_hostname.buckets.doc_count'
But I can't draw the each doc_count Number data. (Only Count, Avg, Max, Min, ...)
How can I set up?
{
"_index": "count7",
"_type": "_doc",
"_id": "1",
"_version": 1,
"_score": null,
"_source": {
"took": 2,
"timed_out": false,
"_shards": {
"total": 9,
"successful": 9,
"skipped": 0,
"failed": 0
},
"hits": {
"total": {
"value": 10000,
"relation": "gte"
},
"max_score": null,
"hits": []
},
"aggregations": {
"by_day_hostname": {
"buckets": [
{
"key_as_string": "2020-01-01T00:00:00.000+09:00",
"key": 1577804400000,
"doc_count": 12323166,
"group_by_hostname": {
"doc_count_error_upper_bound": 0,
"sum_other_doc_count": 0,
"buckets": [
{
"key": "fttxds11",
"doc_count": 1687238
},
{
"key": "fttxds23",
"doc_count": 1616207
},
{
"key": "fttxds22",
"doc_count": 1604213
},
{
"key": "fttxds13",
"doc_count": 1562349
},
{
"key": "fttxds21",
"doc_count": 1543246
},
{
"key": "fttxds12",
"doc_count": 1514070
},
{
"key": "hfcds12",
"doc_count": 477981
},
{
"key": "hfcds13",
"doc_count": 476963
},
{
"key": "hfcds11",
"doc_count": 474847
},
{
"key": "hfcds22",
"doc_count": 464160
},
{
"key": "hfcds21",
"doc_count": 445913
},
{
"key": "hfcds23",
"doc_count": 396649
},
{
"key": "fttxds10",
"doc_count": 19255
},
{
"key": "fttxds20",
"doc_count": 15784
},
{
"key": "hfcds10",
"doc_count": 14104
},
{
"key": "hfcds20",
"doc_count": 10187
}
]
}
},
{
"key_as_string": "2020-01-02T00:00:00.000+09:00",
"key": 1577890800000,
"doc_count": 18893783,
"group_by_hostname": {
"doc_count_error_upper_bound": 0,
"sum_other_doc_count": 0,
"buckets": [
{
"key": "fttxds11",
"doc_count": 2565277
},
{
"key": "fttxds23",
"doc_count": 2456872
},
{
"key": "fttxds22",
"doc_count": 2434604
},
{
"key": "fttxds13",
"doc_count": 2362570
},
{
"key": "fttxds21",
"doc_count": 2335055
},
{
"key": "fttxds12",
"doc_count": 2298125
},
{
"key": "hfcds12",
"doc_count": 748473
},
{
"key": "hfcds13",
"doc_count": 744291
},
{
"key": "hfcds11",
"doc_count": 740777
},
{
"key": "hfcds22",
"doc_count": 726162
},
{
"key": "hfcds21",
"doc_count": 699076
},
{
"key": "hfcds23",
"doc_count": 618349
},
{
"key": "hfcds10",
"doc_count": 41276
},
{
"key": "hfcds20",
"doc_count": 41199
},
{
"key": "fttxds10",
"doc_count": 40855
},
{
"key": "fttxds20",
"doc_count": 40822
}
]
}
},
{
"key_as_string": "2020-01-03T00:00:00.000+09:00",
"key": 1577977200000,
"doc_count": 18936583,
"group_by_hostname": {
"doc_count_error_upper_bound": 0,
"sum_other_doc_count": 0,
"buckets": [
{
"key": "fttxds11",
"doc_count": 2577349
},
{
"key": "fttxds23",
"doc_count": 2463224
},
{
"key": "fttxds22",
"doc_count": 2447495
},
{
"key": "fttxds13",
"doc_count": 2373604
},
{
"key": "fttxds21",
"doc_count": 2346990
},
{
"key": "fttxds12",
"doc_count": 2306665
},
{
"key": "hfcds12",
"doc_count": 744051
},
{
"key": "hfcds13",
"doc_count": 741171
},
{
"key": "hfcds11",
"doc_count": 735819
},
{
"key": "hfcds22",
"doc_count": 724678
},
{
"key": "hfcds21",
"doc_count": 695005
},
{
"key": "hfcds23",
"doc_count": 616356
},
{
"key": "hfcds10",
"doc_count": 41272
},
{
"key": "hfcds20",
"doc_count": 41200
},
{
"key": "fttxds20",
"doc_count": 40864
},
{
"key": "fttxds10",
"doc_count": 40840
}
]
}
}
]
}
}
}
}