Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-18376

Interface changes for SERVER-18099 broke C# 1.0 drivers from access to 3.1.x servers

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 3.1.5
    • Affects Version/s: None
    • Component/s: Diagnostics
    • Fully Compatible
    • ALL
    • Hide

      Any C# app running a 1.x version of the driver against a >= 3.1 server

      Show
      Any C# app running a 1.x version of the driver against a >= 3.1 server
    • BUILD 4 06/05/15, Build 5 06/26/16

      Env: Single mongod 3.1.3 pre

      Problem: an interface change been introduced by server-18099 and broke any C# app compiled w/ C# 1.0.x driver.

      This will likely to slow down the adoption of 3.2 b/c customers will need to recompile the apps and solve other issues.

      see problem stack trace
      see communication below with Craig Wilson

      
      Unhandled Exception: MongoDB.Driver.MongoConnectionException: Unable to connect to server eitan5:27017: Element 'bits' not found.. ---> System.Collections.Generic.KeyNotFoundException: Element 'bits' not found.
         at MongoDB.Bson.BsonDocument.get_Item(String name)
         at MongoDB.Driver.MongoServerBuildInfo.FromCommandResult(CommandResult result)
         at MongoDB.Driver.MongoServerInstance.LookupServerInformation(MongoConnection connection)
         at MongoDB.Driver.MongoServerInstance.Connect()
         at MongoDB.Driver.Internal.DirectMongoServerProxy.Connect(TimeSpan timeout, ReadPreference readPreference)
         --- End of inner exception stack trace ---
         at MongoDB.Driver.Internal.DirectMongoServerProxy.Connect(TimeSpan timeout, ReadPreference readPreference)
         at MongoDB.Driver.Internal.DirectMongoServerProxy.ChooseServerInstance(ReadPreference readPreference)
         at MongoDB.Driver.MongoServer.RequestStart(MongoDatabase initialDatabase, ReadPreference readPreference)
         at MongoDB.Driver.GridFS.MongoGridFS.Upload(Stream stream, String remoteFileName, MongoGridFSCreateOptions createOptions)
         at MongoDB.Driver.GridFS.MongoGridFS.Upload(Stream stream, String remoteFileName)
         at Program.Program.UploadBytes(MongoGridFS handleGridFS, Byte[] dataBytes, Int32 gridId) in c:\src\MyMongoDb\Windows\GridFs\MongoPerfServer\Test.cs:line 51
         at Program.Program.Main(String[] args) in c:\src\MyMongoDb\Windows\GridFs\MongoPerfServer\Test.cs:line 34
      
      
      
      

      Eitan
      Is this change will break any C# app?
      Craig
      this change would break any C# app running a 1.x version of the driver against a >= 3.1 server
      Eitan
      what's the latest version of C# drivers we have today?
      Craig
      1.10.0 and 2.0.0
      Eitan
      OK, so 2.0 should be a workaround for me
      Craig
      2.0.0 is a large upgrade, so I don't expect large enterprises with large apps to have upgraded yet
      it has some breaking changes, etc...

            Assignee:
            jonathan.reams@mongodb.com Jonathan Reams
            Reporter:
            eitan.klein Eitan Klein
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: