Uploaded image for project: 'C# Driver'
  1. C# Driver
  2. CSHARP-2403

Log any unexpected exceptions that occur in SDAM code

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major - P3 Major - P3
    • 2.7.1
    • None
    • Connectivity, Diagnostics
    • None

    Description

      There are at least two places in the SDAM code where exceptions are ignored. See:

      https://github.com/mongodb/mongo-csharp-driver/blob/v2.7.0/src/MongoDB.Driver.Core/Core/Servers/ServerMonitor.cs#L127

      https://github.com/mongodb/mongo-csharp-driver/blob/v2.7.0/src/MongoDB.Driver.Core/Core/Clusters/MultiServerCluster.cs#L229

      To be fair, we don't actually expect exceptions in either of these places, which is why ignoring them hasn't generally been a problem.

      However, any exceptions that might occur here due to bugs in the driver should not be ignored, so we should capture them and log them in some way.

      Attachments

        Activity

          People

            robert@mongodb.com Robert Stam
            robert@mongodb.com Robert Stam
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: