Remove trace logging

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Done
    • Priority: Unknown
    • 1.16.0
    • Affects Version/s: None
    • Component/s: None
    • Not Needed
    • 🔵 Done
    • None
    • None
    • None
    • None
    • None
    • None

      Summary
      Remove trace logging.

      Background & Motivation

      Example of trace logging:

      if (ctx->crypt->log.trace_enabled) {
          char *cmd_val;
          cmd_val = _mongocrypt_new_json_string_from_binary(msg);
          _mongocrypt_log(&ctx->crypt->log, MONGOCRYPT_LOG_LEVEL_TRACE, "%s (%s=\"%s\")", BSON_FUNC, "msg", cmd_val);
          bson_free(cmd_val);
      }
      

      Trace logging is enabled by both:

      • At compile-time: use the CMake option ENABLE_TRACE=ON
      • At run-time: set the environment variable MONGOCRYPT_TRACE=ON

      https://github.com/mongodb/libmongocrypt/pull/976/ is a report of a build error when configuring with ENABLE_TRACE=ON.

      This ticket proposes removing trace logging. The libmongocrypt binaries drivers include are not built with ENABLE_TRACE=ON. I expect it is unused, untested, and (IMO) not worth keeping.

            Assignee:
            Julia Garland
            Reporter:
            Kevin Albertson
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: