Change time_zone in date_histogram composite aggregation does not work?

here my mapping
mapping file
then i try rerquest using like this
Request
the result like this


> {
>     "took": 1782,
>     "timed_out": false,
>     "_shards": {
>         "total": 10,
>         "successful": 10,
>         "skipped": 0,
>         "failed": 0
>     },
>     "hits": {
>         "total": {
>             "value": 10000,
>             "relation": "gte"
>         },
>         "max_score": null,
>         "hits": []
>     },
>     "aggregations": {
>         "histograms2": {
>             "buckets": [
>                 {
>                     "key_as_string": "2019-11-18",
>                     "key": 1574010000000,
>                     "doc_count": 1992566
>                 },
>                 {
>                     "key_as_string": "2019-11-19",
>                     "key": 1574096400000,
>                     "doc_count": 2440622
>                 }
>             ]
>         },
>         "statistic": {
>             "after_key": {
>                 "date_f": "2019-11-17",
>                 "country": "Australia",
>                 "region": "Australian Capital Territory",
>                 "city": "Canberra",
>                 "device_type": "Mobile",
>                 "device_brand": "Apple",
>                 "device_model": "iPhone",
>                 "os_name": "iOS",
>                 "browser_name": "Chrome"
>             },
>             "buckets": [
>                 {
>                     "key": {
>                         "date_f": "2019-11-17",
>                         "country": "",
>                         "region": "",
>                         "city": "",
>                         "device_type": "Desktop",
>                         "device_brand": "-",
>                         "device_model": "-",
>                         "os_name": "Linux",
>                         "browser_name": "Chrome"
>                     },
>                     "doc_count": 1,
>                     "sum_impressions": {
>                         "value": 1.0
>                     },
>                     "sum_requests": {
>                         "value": 1.0
>                     },
>                     "sum_clicks": {
>                         "value": 0.0
>                     }
>                 },
>                 {
>                     "key": {
>                         "date_f": "2019-11-17",
>                         "country": "",
>                         "region": "",
>                         "city": "",
>                         "device_type": "Desktop",
>                         "device_brand": "-",
>                         "device_model": "-",
>                         "os_name": "OS X",
>                         "browser_name": "Opera"
>                     },
>                     "doc_count": 5,
>                     "sum_impressions": {
>                         "value": 6.0
>                     },
>                     "sum_requests": {
>                         "value": 6.0
>                     },
>                     "sum_clicks": {
>                         "value": 0.0
>                     }
>                 },
>                 {
>                     "key": {
>                         "date_f": "2019-11-17",
>                         "country": "",
>                         "region": "",
>                         "city": "",
>                         "device_type": "Desktop",
>                         "device_brand": "-",
>                         "device_model": "-",
>                         "os_name": "Ubuntu",
>                         "browser_name": "Firefox"
>                     },
>                     "doc_count": 1,
>                     "sum_impressions": {
>                         "value": 1.0
>                     },
>                     "sum_requests": {
>                         "value": 1.0
>                     },
>                     "sum_clicks": {
>                         "value": 0.0
>                     }
>                 },
>                 {
>                     "key": {
>                         "date_f": "2019-11-17",
>                         "country": "",
>                         "region": "",
>                         "city": "",
>                         "device_type": "Desktop",
>                         "device_brand": "-",
>                         "device_model": "-",
>                         "os_name": "Windows",
>                         "browser_name": "Chrome"
>                     },
>                     "doc_count": 301,
>                     "sum_impressions": {
>                         "value": 701.0
>                     },
>                     "sum_requests": {
>                         "value": 701.0
>                     },
>                     "sum_clicks": {
>                         "value": 0.0
>                     }
>                 }

from that result date_histogram outside composite have correct result the date formatted to time zone "Asia/Jakarta", but from result date_histogram that inside composite didn't formatted , this is bug ?

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.