Hi All,
I am using cursor.toArray()
to return my collection.find(query)
as a list and response time for my API is in 100's of milliseconds. Data fetched into the cursor is very less (a couple of hundred records), the database is indexed on the field I am querying. I have also set the batch size cursor.batchSize(1000)
.
db.collection.find({"{ "ZIP" : { "$in" : [ "12345"]}}"}.toArray()
is my query, and my database is indexed on 'ZIP' . I can see the same query running on the shell within 4 ms.
Mogo driver I am using is: mongojack 2.8.2.
I timed my applications and cursor.toArray() is where is see the bottle neck. I can provide additional details and sample of application code if needed.
Any insights into getting better performance are appreciated.
Thanks.
Sudharshan.
--
You received this message because you are subscribed to the Google Groups "mongo-jackson-mapper" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mongo-jackson-ma...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.