Uploaded image for project: 'Drivers'
  1. Drivers
  2. DRIVERS-281

Rephrase unsupported/corrupt BSON messages

    • Type: Icon: Improvement Improvement
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Component/s: None
    • None

      Soon – pretty very soon – MongoDB will be introducing new BSON types.
      Although old drivers may not be connecting to MongoDB versions using that BSON types, bson dump files and whatnot will eventually contain these types and these files shoved through old driver versions.

      Currently most drivers fail with very confusing error messages, especially if you are actually connected to a MongoDB supporting these types.

      This ticket is about unifying this error message to be more friendly and possibly alerting the user that newer drivers may support this type and the BSON may not actually be corrupt as currently reported.

      Detected unknown BSON type "\xTYPE" for fieldname "NAME". Are you using the latest driver version?

      Where

      • TYPE is the current field type
      • NAME is the current field name, if possible

      The type name should be represented in hex confirming to our BSON Spec convention '\x00'.

      The field name may not be possible to include in drivers, but drivers SHOULD make BEST EFFORT to include it. It helps our users a great deal as they could potentially project that field out as a poor mans workaround.
      It is not required to provide the fieldname using dotnotation for nested fields. The inner most fieldname is sufficient.

      Please ensure this is done for all currently actively - AND INACTIVELY - maintained drivers.

            Assignee:
            Unassigned Unassigned
            Reporter:
            bjori Hannes Magnusson
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: