opensearch-java icon indicating copy to clipboard operation
opensearch-java copied to clipboard

DateHistogramValuesSourceBuilder - offset support

Open muzehyun opened this issue 2 years ago • 4 comments
trafficstars

Is your feature request related to a problem? Please describe. Can't specify "offset" parameter for date_histogram with OpenSearch java client. Current offset parameter is used differently (rounding).

Describe the solution you'd like A way to specify offset.

Describe alternatives you've considered Replace current offset function usage or create new. - "dateHistogramOffset()"

Additional context Add any other context or screenshots about the feature request here.

In request json body, no way to set "offset" with java client.

{
    "date_histogram":
    {
        "field": "timestamp",
        "calendar_interval": "1w",
        "offset": "-1d",
    }
}

muzehyun avatar Oct 31 '23 18:10 muzehyun

@muzehyun This looks to be java client related functionality gap. Can you create the issue in this repo please ?

sohami avatar Nov 03 '23 06:11 sohami

I'm still using "rest-high-level" client here in this repo. No major update on rest-high-level-client? Should I move to new Java client?

muzehyun avatar Nov 10 '23 23:11 muzehyun

@muzehyun Yes you should. Moving this issue into opensearch-java.

dblock avatar Nov 16 '23 17:11 dblock

@muzehyun Want to try to use the latest version of the client? Does it work?

dblock avatar Dec 04 '23 15:12 dblock