Uploaded image for project: 'C++ Driver'
  1. C++ Driver
  2. CXX-1232

Backport 'CXX-1226 Resolve json.cpp compile warnings introduced by deprecation of bson_as_json' for 3.1.2

    • Type: Icon: Bug Bug
    • Resolution: Gone away
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Build
    • Labels:
      None

      This ticket tracks the backport of CXX-1226. Original description for CXX-1226:

      As of the upcoming 1.7.0 libbson release, bson_as_json() is being deprecated by the introduction of bson_as_extended_json(). See related ticket CDRIVER-1947.

      We should disable this deprecation warning via CXX-1056.

      Example of the output being generated by this warning:

      [2017/02/22 18:53:36.239] /data/mci/b73b54737441c65057f5e95736a1bde9/mongo-cxx-driver/src/bsoncxx/json.cpp:52:19: error: 'bson_as_json' is deprecated [-Werror,-Wdeprecated-declarations]
      [2017/02/22 18:53:36.239]     auto result = bson_as_json(&bson, &size);
      [2017/02/22 18:53:36.239]                   ^
      [2017/02/22 18:53:36.239] /data/mci/b73b54737441c65057f5e95736a1bde9/mongo-cxx-driver/../mongoc/include/libbson-1.0/bson.h:508:1: note: 'bson_as_json' has been explicitly marked deprecated here
      [2017/02/22 18:53:36.239] bson_as_json (const bson_t *bson, size_t *length)
      [2017/02/22 18:53:36.239] ^
      [2017/02/22 18:53:36.268] 1 error generated.
      

            Assignee:
            rassi J Rassi
            Reporter:
            rassi J Rassi
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: