Env:
Java: 1.8
Mongo db: 2.6.7
Mongo-java driver: 2.12.0
Apache-Tomcat: 7.0.53
Error
I get these errors when I am closing the connections in mongo cursor. These are potential memory leaks.
Log
java.lang.IllegalStateException: open
at org.bson.util.Assertions.isTrue(Assertions.java:36) ~[mongo-java-driver-2.12.0.jar:na]
at com.mongodb.DBTCPConnector.isMongosConnection(DBTCPConnector.java:374) ~[mongo-java-driver-2.12.0.jar:na]
at com.mongodb.Mongo.isMongosConnection(Mongo.java:645) ~[mongo-java-driver-2.12.0.jar:na]
at com.mongodb.DBCursor._check(DBCursor.java:454) ~[mongo-java-driver-2.12.0.jar:na]
at com.mongodb.DBCursor._hasNext(DBCursor.java:546) ~[mongo-java-driver-2.12.0.jar:na]
at com.mongodb.DBCursor.hasNext(DBCursor.java:571) ~[mongo-java-driver-2.12.0.jar:na]
.......
Any fix available?