|[jnosql-dev] add cont() method to the MongoDBTemplate|
Could you add the count() method to the MongoDBTemplate ?
Currently I use select(collectionName, bson).count(), but this is a huge performance hog.
* Returns the number of items in the collection that match the given query filter.
* @param collectionName the collection name
* @param filter the query filter
* @return the number of documents from query
* @throws NullPointerException when filter or collectionName is null
long count(String collectionName, Bson filter);
Back to the top