New JAVA API Documentation

Hello, first of all congratulations on the new version of Elastic. A month ago we were translating a java software that uses Elasticsearch. We switched to the new Java API (with very poor documentation) and it took a lot of effort. What has been our surprise, going from 7.17 to 8.1, things have changed again. Do you plan to improve the documentation to be able to use it? Can you help me with the change that has occurred in the UpdateOperation?

JAVA API 7.17
The update operation accepts the T document.

...
UpdateOperation.Builder<T> b = new UpdateOperation.Builder<>();
operations.add(new BulkOperation(b.document(doc).index(index).id(id).build()));
...

JAVA API 8.1
The update operation needs TDocument, TPartialDocument and I don't know how it uses.
The T document builder method don't exists, only tDocumentSerializer or tPartialDocumentSerializer but I don't know hoy use it.

Documention is currently one of the biggest priorities for the new Java Client. See Issues · elastic/elasticsearch-java · GitHub

Regarding your second question: Maybe this test snippet helps? elasticsearch-java/RequestTest.java at main · elastic/elasticsearch-java · GitHub

Thanks a lot! I will follow the links!

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