Andriy Redko

Results 791 comments of Andriy Redko

Please refer to https://github.com/opensearch-project/opensearch-java/issues/257 , the client would benefit from generalized approach.

@dblock there are few options, may be the easiest one is to convert it to a map: ``` Map responseAsMap = response.getBody() .map(b -> Bodies.json(b, Map.class, javaClient()._transport().jsonpMapper())) .orElseGet(Collections::emptyMap); ```

As a follow up, we could support "generic" JSON structures, like: - `jakarta.json.JsonStructure` - `com.fasterxml.jackson.databind.JsonNode` (depending which mapper is configured) ``` JsonNode json = response.getBody() .map(b -> Bodies.json(b, JsonNode.class, javaClient()._transport().jsonpMapper()))...

> Any reason not to expose .bodyAsJson() implemented as the above that returns JsonNode? So at the moment, we have 2 implementations of `JsonpMapper`: - `JsonbJsonpMapper` (Jakarta) - `JacksonJsonpMapper` (Jackson)...

I would agree with @andrross, I would consider it to be baked into core (in most efficient way possible) since it is directly improving the usability of search when asynchronicity...

@amirhalatzi the OpenSearch 2.x has JDK-11 baseline (the connector works with 2.x as well). Please correct me if I am wrong, Apache Flink still supports JDK 8 (although it is...

> @reta you're right. Java 8 is still [supported](https://issues.apache.org/jira/browse/FLINK-25244). As for the current connector working with 2.x - you can see in the PR that the API has changed. Any...

@zentol @MartijnVisser would appreciate if you guys have time for the review, adding AsyncSink support for OpenSearch, discussed initially [1] [1] https://github.com/apache/flink/pull/18541#issuecomment-1026931087

@zentol @MartijnVisser doing my one per month ping diligence :-), please