How can you perform source filtering with the Java High Level Rest Client
For example if I'm doing a reindex request, I would do something like the following to only include the fields which are relevant to me.
POST _reindex
{
"source": {
"index": "twitter",
"_source": ["user", "_doc"]
},
"dest": {
"index": "new_twitter"
}
}
Is it even possible to achieve the same through the Java Client's ReindexRequest?
ReindexRequest reindexRequest = new ReindexRequest();
reindexRequest.setSourceIndices("twitter");
reindexRequest.setDestIndex("new_twitter");
// how can you set the fields to include?