I’m using the last version of OpenSearch (2.4.x) and I want to know if it is possible to get the Json DSL of a query performed. For example:
I have this query in the java client
Query query = new Query.Builder()
.match(new MatchQuery.Builder()
.field("machine.os.keyword")
.query(q -> q.stringValue("osx"))
.build())
.build();
I want to get the DSL equivalent
{
"query": {
"match": {
"machine.os.keyword": "osx"
}
}
}