Documentation for UpdateOperation

Is there any documentation for using UpdateOperation with the new Java API Client. I can't seem to find any. Some examples would be helpful. Thanks.

Hi @toddcarv

Maybe this example can help you.

Using builder style:

UpdateOperation<Movie, Movie> updateOperation = new UpdateOperation.Builder<Movie, Movie>()
    .action(a -> a.doc(movie))

var operation = new BulkOperation.Builder().update(updateOperation).build();

var bulkRequest = new BulkRequest.Builder().operations(List.of(operation)).build();

var response = client.bulk(bulkRequest);


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