com.mongodb.MongoSocketReadException: Prematurely reached end of stream

Stack Overflow | gasparms | 2 years ago
tip
Do you find the tips below useful? Click on the to mark them and say thanks to rafael . Or join the community to write better ones.
  1. 0
    samebug tip
    Check if your server is listening to the the same adress you're trying to connect to.
  2. 0

    Can't connect from JAVA to Mongo SSL Replica Set

    Stack Overflow | 2 years ago | gasparms
    com.mongodb.MongoSocketReadException: Prematurely reached end of stream
  3. 0

    Connecting to mongo database through SSH tunnel in Java

    Stack Overflow | 2 years ago | David V
    com.mongodb.MongoSocketReadException: Prematurely reached end of stream
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    How to connect to mongodb from c9.io?

    GitHub | 11 months ago | salmazov
    com.mongodb.MongoSocketReadException: Prematurely reached end of stream
  6. 0

    Mongeeze failed with replicaset and mongoProperties.setUri used

    GitHub | 1 year ago | UltimateFighter
    com.mongodb.MongoSocketReadException: Prematurely reached end of stream

    6 unregistered visitors
    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. com.mongodb.MongoSocketReadException

      Prematurely reached end of stream

      at com.mongodb.connection.SocketStream.read()
    2. MongoDB Java Driver
      DefaultServerMonitor$ServerMonitorRunnable.run
      1. com.mongodb.connection.SocketStream.read(SocketStream.java:88)
      2. com.mongodb.connection.InternalStreamConnection.receiveResponseBuffers(InternalStreamConnection.java:491)
      3. com.mongodb.connection.InternalStreamConnection.receiveMessage(InternalStreamConnection.java:221)
      4. com.mongodb.connection.CommandHelper.receiveReply(CommandHelper.java:134)
      5. com.mongodb.connection.CommandHelper.receiveCommandResult(CommandHelper.java:121)
      6. com.mongodb.connection.CommandHelper.executeCommand(CommandHelper.java:32)
      7. com.mongodb.connection.InternalStreamConnectionInitializer.initializeConnectionDescription(InternalStreamConnectionInitializer.java:83)
      8. com.mongodb.connection.InternalStreamConnectionInitializer.initialize(InternalStreamConnectionInitializer.java:43)
      9. com.mongodb.connection.InternalStreamConnection.open(InternalStreamConnection.java:115)
      10. com.mongodb.connection.DefaultServerMonitor$ServerMonitorRunnable.run(DefaultServerMonitor.java:127)
      10 frames
    3. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:745)
      1 frame