Uploaded image for project: 'Couchbase C client library libcouchbase'
  1. Couchbase C client library libcouchbase
  2. CCBC-1485

lcb_cntl LCB_CNTL_ENABLE_TRACING not disabling tracing

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 3.2.0
    • 3.2.2
    • library
    • None
    • 1

    Description

      From debugging session I found following behaviour.

      lcb_create creates a tracer per code in tracing.cc. 

      if (settings->use_tracing) {
      if (options && options->tracer)

      { settings->tracer = options->tracer; }

      else

      { settings->tracer = lcbtrace_new(obj, LCBTRACE_F_THRESHOLD); }

      }

      Given settings->use_tracing seems to always be 1 this is always executed.

      subsequent lcb_cntl call setting LCB_CNTL_ENABLE_TRACING to 0 just sets settings->use_tracing to 0 but does not touch settings->tracer which is tested for calling tracing code.

      Attachments

        For Gerrit Dashboard: CCBC-1485
        # Subject Branch Project Status CR V

        Activity

          jo JC created issue -
          avsej Sergey Avseyev made changes -
          Field Original Value New Value
          Status New [ 10003 ] Open [ 1 ]
          avsej Sergey Avseyev made changes -
          Fix Version/s 3.2.2 [ 17647 ]
          avsej Sergey Avseyev made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          avsej Sergey Avseyev made changes -
          Resolution Fixed [ 1 ]
          Status In Progress [ 3 ] Resolved [ 5 ]
          jo JC added a comment -

          Follow up comment, first of all thanks for the fix, it works but I was wondering why this tracing feature is enabled by default ? Given it adds overhead on the client, should not it be disabled by default and only active if one calls lcb_cntl function ?

          Thanks

           

          jo JC added a comment - Follow up comment, first of all thanks for the fix, it works but I was wondering why this tracing feature is enabled by default ? Given it adds overhead on the client, should not it be disabled by default and only active if one calls lcb_cntl function ? Thanks  

          Build couchbase-server-7.1.0-1450 contains libcouchbase commit c6c61f5 with commit message:
          CCBC-1485: allow to disable tracer for connected instance

          build-team Couchbase Build Team added a comment - Build couchbase-server-7.1.0-1450 contains libcouchbase commit c6c61f5 with commit message: CCBC-1485 : allow to disable tracer for connected instance

          People

            avsej Sergey Avseyev
            jo JC
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty