System.IO.EndOfStreamException: Attempted to read past the end of the stream.

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Major - P3
    • None
    • Affects Version/s: 1.9
    • Component/s: None
    • None
    • Environment:
      Microsoft Windows Server 2012 R2 Standard
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Since we are using the 1.9 driver we started noticing the following exception popup (11 occurrences). We have 2 occurrences of this happening with 1.8 but it seems to be happening a ton more with 1.9. I'm sorry I don't have a repro but I believe it had to do with passing hundreds of excludes into a not in condition (which we have fixed). But I figured I'd submit a bug for it just to bring it to your attention:

      System.IO.EndOfStreamException: Attempted to read past the end of the stream.
      at MongoDB.Bson.IO.ByteBufferFactory.LoadFrom(Stream stream)
      at MongoDB.Driver.Internal.MongoConnection.ReceiveMessage[TDocument](BsonBinaryReaderSettings readerSettings, IBsonSerializer serializer, IBsonSerializationOptions serializationOptions)
      at MongoDB.Driver.Operations.CommandOperation`1.Execute(MongoConnection connection)
      at MongoDB.Driver.MongoCollection.RunCommandAs[TCommandResult](IMongoCommand command, IBsonSerializer resultSerializer, IBsonSerializationOptions resultSerializationOptions)
      at MongoDB.Driver.MongoCollection.RunCommandAs[TCommandResult](IMongoCommand command)
      at MongoDB.Driver.MongoCollection.Count(CountArgs args)

            Assignee:
            Unassigned
            Reporter:
            Blake Niemyjski
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: