java.lang.NullPointerException: null

JIRA | Daniel Peters | 6 years ago
tip
Do you know that we can give you better hits? Get more relevant results from Samebug’s stack trace search.
  1. 0

    After running for some days without problems I just get NullPointerExceptions for every operation. I restarted my application (not the server) and the mongo-driver worked again. The first error: java.lang.NullPointerException: null at com.mongodb.DBTCPConnector$MyPort.get(DBTCPConnector.java:274) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBTCPConnector.call(DBTCPConnector.java:205) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBApiLayer$MyCollection.__find(DBApiLayer.java:284) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DB.command(DB.java:152) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DB.command(DB.java:141) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DB.getLastError(DB.java:302) ~[mongo-java-driver-2.3.jar:na] and afterwards for example: Caused by: java.lang.NullPointerException: null at com.mongodb.DBTCPConnector$MyPort.get(DBTCPConnector.java:274) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBTCPConnector.call(DBTCPConnector.java:205) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBApiLayer$MyCollection.__find(DBApiLayer.java:284) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DB.command(DB.java:152) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBCollection.getCount(DBCollection.java:642) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBCollection.getCount(DBCollection.java:616) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBCursor.count(DBCursor.java:555) ~[mongo-java-driver-2.3.jar:na] java.lang.NullPointerException: null at com.mongodb.DBTCPConnector$MyPort.get(DBTCPConnector.java:274) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBTCPConnector.say(DBTCPConnector.java:151) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBTCPConnector.say(DBTCPConnector.java:141) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBApiLayer$MyCollection.update(DBApiLayer.java:317) ~[mongo-java-driver-2.3.jar:na] at com.mongodb.DBCollection.update(DBCollection.java:112) ~[mongo-java-driver-2.3.jar:na]

    JIRA | 6 years ago | Daniel Peters
    java.lang.NullPointerException: null

    Root Cause Analysis

    1. java.lang.NullPointerException

      null

      at com.mongodb.DBTCPConnector$MyPort.get()
    2. MongoDB Java Driver
      DB.getLastError
      1. com.mongodb.DBTCPConnector$MyPort.get(DBTCPConnector.java:274)[mongo-java-driver-2.3.jar:na]
      2. com.mongodb.DBTCPConnector.call(DBTCPConnector.java:205)[mongo-java-driver-2.3.jar:na]
      3. com.mongodb.DBApiLayer$MyCollection.__find(DBApiLayer.java:284)[mongo-java-driver-2.3.jar:na]
      4. com.mongodb.DB.command(DB.java:152)[mongo-java-driver-2.3.jar:na]
      5. com.mongodb.DB.command(DB.java:141)[mongo-java-driver-2.3.jar:na]
      6. com.mongodb.DB.getLastError(DB.java:302)[mongo-java-driver-2.3.jar:na]
      6 frames