Uploaded image for project: 'C++ Couchbase Client'
  1. C++ Couchbase Client
  2. CXXCBC-326

Set connection_string warnings property when invalid connection string parameter encountered

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Done
    • Major
    • None
    • 1.0.0-dp.6
    • library
    • None
    • 1
    • SDK20

    Description

      In order to help with user experience, it would probably be better to set the connect_string error property when an invalid connection string value is encountered. See JSCBC-1156 linked for an example of user providing an invalid tls_verify_mode option. It will still be up to the wrappers to check for the error and raise the appropriate exception, but when at least the Node.js and Python wrappers use the couchbase::core::utils::parse_connection_string method, so would be nice to have the C++ client set errors during parsing.

      Ref:
      https://github.com/couchbaselabs/couchbase-cxx-client/blob/main/core/utils/connection_string.cxx

      Proposed solution: The existing errors property should be left for errors that will terminate the parsing. Add a new warnings connection_string property for parsing issues like invalid options that do not need to terminate the parsing. All warnings should be accumulated there and the caller (wrapper or C++ Public API) can decide whether to log them or raise an exception.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              Dimitris.Christodoulou Dimitris Christodoulou
              jared.casey Jared Casey
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes