visitUUIDConstructor always return BsonBinarySubType.UUID_LEGACY

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Duplicate
    • Priority: Major - P3
    • None
    • Affects Version/s: 4.0.5
    • Component/s: JSON
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The condition in visitUUIDConstructor is always true and make it return a UUID_LEGACY regardless of the uuidConstructorName

       

      {{ BsonBinarySubType subType = BsonBinarySubType.UUID_STANDARD;
      if (!"UUID".equals(uuidConstructorName) || !"GUID".equals(uuidConstructorName)) {
      subType = BsonBinarySubType.UUID_LEGACY;
      }}}

      {{}}

      Fix: https://github.com/mongodb/mongo-java-driver/pull/556

       

      This is not present in 4.1.x as Legacy support has been dropped.

              Assignee:
              Jeffrey Yemin
              Reporter:
              Loïc Hermann
              None
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: