Describe the bug
When using the composite aggregation with a date_histogram, time-zone offsets used by the 'after_key' reference are not handled correctly.
Identified version: 1.3.9
The first request returns an after_key (combination of columns of last aggregation record). This after_key is used as the 'after' parameter in the second request.
The second request's result contains duplicated or skipper records (depending on the time zone used) - The after_key's timestamp reference is not adjusted based on the time zone. E.g., when using timezone with UTC+5, the second request will contain results starting with a timestamp that is 5 hours before the timestamp of the first aggregation's last record.
When cycling through the paged result using the 'after_key', the total number of aggregation results differ based on the time zone used (only UTC returns the correct results)
Expected behavior
OpenSearch should be able to consider the timezone of the after_key timestamp reference
Describe the bug When using the composite aggregation with a date_histogram, time-zone offsets used by the 'after_key' reference are not handled correctly. Identified version: 1.3.9
To Reproduce Steps to reproduce the behavior:
Expected behavior OpenSearch should be able to consider the timezone of the after_key timestamp reference