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

BsonClassMap.LookupClassMap supports private constructors inconsistently (regression)

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Gone away
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Serialization
    • Labels:
      None

      Description

      The user's email:

      Ello 
      After upgrading the c# mongo driver from 2.10.1 to 2.10.2, I noticed that classes that deserialised without issues suddenly stopped working, resulting in exceptions about incorrect creator maps. Has something changed with this patch?
      The class I'm deserialising has a private, parameterless constructor, and a public constructor with 4 arguments. I get the following exception since the patch:
      Creator map for class Nallian.CargoFlow.UseCase.Models.Mawb.PiecesDetail has 4 arguments, but none are configured.
      Any ideas what has gone wrong? I don't see documented changes regarding the mapping, might the change be unintended? Moving back to 2.10.1 has resolved the issue again, leading me to believe there's something with the most recent patch.
      Kind regards, Anthony

       

       

        Attachments

          Activity

            People

            Assignee:
            dmitry.lukyanov Dmitry Lukyanov
            Reporter:
            dmitry.lukyanov Dmitry Lukyanov
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: