I am actually migrating from arango to mongo . I did the query in arango web client and pasted the query with argument parameters in @query the results were the same.
It seemed that I can skip the mongo repository and get results using Mongo template but I don’t know why the results are not the same .
My issue is that the output in Spring is different from the output in Compass . And you are also getting the same results , I guess there is a bug in Sping , But can you share how did you use the Java driver for that query.