Uploaded image for project: 'C Driver'
  1. C Driver
  2. CDRIVER-4795

Restore MONGOC_MD_FLAG_ENABLE_ICU

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 1.25.4
    • Affects Version/s: 1.25.0
    • Component/s: None
    • None

      Summary

      Restore the enum value MONGOC_MD_FLAG_ENABLE_ICU removed in CDRIVER-4680 to restore the subsequent values.

      Background & Motivation

      CDRIVER-4680 removed the MONGOC_MD_FLAG_ENABLE_ICU from the handshake config.

      The handshake config is reported in the client metadata sent to the server. Here are examples from the mongod logs (see cfg=0x0300deaa65) for C driver 1.24.3 and 1.25.0:

      {"t":{"$date":"2023-12-13T13:00:39.283-05:00"},"s":"I",  "c":"NETWORK",  "id":51800,   "ctx":"conn13","msg":"client metadata","attr":{"remote":"127.0.0.1:49998","client":"conn13","doc":{"driver":{"name":"mongoc","version":"1.24.3"},"os":{"type":"Darwin","name":"macOS","version":"21.6.0","architecture":"arm64"},"platform":"cfg=0x0300deaa65 posix=200112 stdc=199901 CC=clang 14.0.0 (clang-1400.0.29.202) CFLAGS=\"\" LDFLAGS=\"\""}}}
      {"t":{"$date":"2023-12-13T13:00:39.374-05:00"},"s":"I",  "c":"NETWORK",  "id":51800,   "ctx":"conn14","msg":"client metadata","attr":{"remote":"127.0.0.1:50000","client":"conn14","doc":{"driver":{"name":"mongoc","version":"1.25.0"},"os":{"type":"Darwin","name":"macOS","version":"21.6.0","architecture":"arm64"},"platform":"cfg=0x0383d6aa65 posix=200112 stdc=199901 CC=clang 14.0.0 (clang-1400.0.29.202) CFLAGS=\"\" LDFLAGS=\"\""}}}
      

      The bits can be interpreted with parse_handshake_cfg.py.

      MONGOC_MD_FLAG_ENABLE_ICU was likely unintentionally removed.
      The removal may add difficultly parsing and comparing config values between driver versions. For example, HELP-52803 reports configs with equal values between driver versions 1.24.3 and 1.25.0. Yet, the interpreted values are different:

      To interpret the flags for 1.24.3, the version of parse_handshake_cfg.py from the r1.24 branch may be used. To parse the flags for 1.25.0, the version of parse_handshake_cfg.py from the r1.25 branch may be used.

      Caveat: restoring the flag would mean C driver versions 1.25.0-(version fixed) would be an exception with different flag parsing.

            Assignee:
            kevin.albertson@mongodb.com Kevin Albertson
            Reporter:
            kevin.albertson@mongodb.com Kevin Albertson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: