BukResponseItem not returning the source document back

Versions (relevant - OpenSearch/Dashboard/Server OS/Browser):
OpenSearch Version: 2.16.0
Java Client: 2.10.1

Describe the issue:
My requirement is to fetch the source document back in the bulk response for each of the bulk response item. This is to post process the dependencies based on the changed data and status.

Can someone please share any examples to achieve this?

I tried below and the response still have the get as null.

BulkRequest.Builder().operations(ops)
.source(SourceConfigParam.Builder().fetch(true).build())
.refresh(Refresh.True).timeout(Time.Builder().time(“1h”).build())
.build()

client.bulk(bulkRequest)

bulkResponse.items().first().get() is null in the response. Ops have only one item here.

It looks like a bug, could you please create an issue here [1]? Thank you

[1] Issues · opensearch-project/opensearch-java · GitHub

Thank you @reta . Created a bug: [BUG] BukResponseItem not returning the source document back · Issue #1322 · opensearch-project/opensearch-java · GitHub