Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-32130

mctimings crashes when trying to get timing data

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 6.5.0
    • 6.5.0
    • couchbase-bucket
    • None
    • Untriaged
    • Yes

    Description

      [Regression] Mctimings crashes when trying to get timing data from couchbase. This is due to it not finding a "error" key, which is looking for so see if there was an error on the server side. However, if it does not find it then we should continue parsing the json data correctly.

      Fix for this is to use the find method of nlohmann::json to see if the error key is present, if not we will carry on parsing the data as before.

      Error message produced by mctimings:

      richarddemellow@EMEA-MAC029:~/source/couchbase/install/bin$ ./mctimings -h 127.0.0.1:11999 -u test -P password -v 
      The following data is collected for "STAT"
      [  20 -   29]us (  6.67%)  1 | ######
      [  40 -   49]us ( 13.33%)  1 | ######
      [  50 -   59]us ( 20.00%)  1 | ######
      [  60 -   69]us ( 26.67%)  1 | ######
      [  70 -   79]us ( 33.33%)  1 | ######
      [ 500 -  509]us ( 40.00%)  1 | ######
      [ 560 -  569]us ( 46.67%)  1 | ######
      [ 990 -  999]us ( 53.33%)  1 | ######
      Total: 15 operations
      The following data is collected for "GET_ALL_VB_SEQNOS"
      [ 350 -  359]us ( 16.67%)  1 | ############################################
      [ 400 -  409]us ( 33.33%)  1 | ############################################
      [ 520 -  529]us ( 50.00%)  1 | ############################################
      [ 530 -  539]us ( 66.67%)  1 | ############################################
      [ 570 -  579]us ( 83.33%)  1 | ############################################
      [ 660 -  669]us (100.00%)  1 | ############################################
      Total: 6 operations
      The following data is collected for "DCP_OPEN"
      [  30 -   39]us ( 25.00%)  2 | #############################
      [  40 -   49]us ( 62.50%)  3 | ############################################
      [  50 -   59]us ( 87.50%)  2 | #############################
      [  60 -   69]us (100.00%)  1 | ##############
      Total: 8 operations
      The following data is collected for "DCP_GET_FAILOVER_LOG"
      [   0 -    9]us ( 98.73%)  1011 | ############################################
      [  10 -   19]us ( 99.71%)    10 | 
      [  20 -   29]us (100.00%)     3 | 
      Total: 1024 operations
      Fatal error: [json.exception.type_error.302] type must be string, but is number
      

      Attachments

        Issue Links

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

          Activity

            People

              richard.demellow Richard deMellow
              richard.demellow Richard deMellow
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty