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

IDL generated code should pass field name to serializer

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor - P4
    • Resolution: Fixed
    • None
    • 5.0.0-rc0
    • Storage
    • None
    • Fully Compatible
    • ALL
    • Execution Team 2021-04-19

    Description

      Most serializer functions for IDL defined types accept both a field name and the BSONObjBuilder. This does not currently apply when the BSON serialization type consists of a list of primitive types. Example

          writeConcernW:
              bson_serialization_type:
                                       - string
                                       - int
                                       - decimal
                                       - double
                                       - long
      

      The serializer function for this IDL type accepts a single BSONObjectBuilder parameter. It would be more consistent if we could amend the contract so that the IDL generated code passes two function parameters to this serializer. This issue is more apparent when converting the bson_serialization_type field from any to a list of basic types.

      Attachments

        Issue Links

          Activity

            People

              benety.goh@mongodb.com Benety Goh
              benety.goh@mongodb.com Benety Goh
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: