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

bucket.ping wrongly returns LCB_UNKNOWN_HOST in the KV list for non-KV nodes

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.8.7
    • Component/s: library
    • Labels:
      None

      Description

      Tested on libcouchbase/2.8.4-njs couchnode/2.4.4

      When running bucket.ping and if there is a node in the cluster that doesn't have the Data Service running on it, the ping result returns the correct nodes, plus an entry in the KV list with an error for nodes that don't have the Data Service running:

      {  
         "config_rev":1068,
         "id":"0x38c72c0",
         "sdk":"libcouchbase/2.8.4-njs couchnode/2.4.4 (node/9.11.1; v8/6.2.414.46-node.23; ssl/1.0.2o)",
         "services":{  
            "kv":[  
               {  
                  "details":"LCB_UNKNOWN_HOST (0x15): DNS/Hostname lookup failed",
                  "latency_us":4048,
                  "remote":":",
                  "scope":"testB",
                  "status":"error"
               },
               {  
                  "id":"0x385ed90",
                  "latency_us":5172,
                  "local":"10.0.2.15:50202",
                  "remote":"10.111.151.101:11210",
                  "scope":"testB",
                  "status":"ok"
               },
               {  
                  "id":"0x38ea6f0",
                  "latency_us":6312,
                  "local":"10.0.2.15:57811",
                  "remote":"10.111.151.102:11210",
                  "scope":"testB",
                  "status":"ok"
               }
            ],
            "n1ql":[  
               {  
                  "id":"0x394dad0",
                  "latency_us":4093,
                  "local":"10.0.2.15:51632",
                  "remote":"10.111.151.103:8093",
                  "status":"ok"
               }
            ],
            "views":[  
               {  
                  "id":"0x38a6cc0",
                  "latency_us":5052,
                  "local":"10.0.2.15:47853",
                  "remote":"10.111.151.101:8092",
                  "status":"ok"
               },
               {  
                  "id":"0x390a5f0",
                  "latency_us":4812,
                  "local":"10.0.2.15:48137",
                  "remote":"10.111.151.102:8092",
                  "status":"ok"
               }
            ]
         },
         "version":1
      }
      

      Code sample:

      var couchbase = require('couchbase')
      var cluster = new couchbase.Cluster('couchbase://10.111.151.101/');
      var bucket = cluster.openBucket('testB');
       
      bucket.ping(["kv", "query", "view"],  function(err, result) {
        if (err) throw err;
        console.log(JSON.stringify(result));
      });
      

        Attachments

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

          Activity

          Hide
          build-team Couchbase Build Team added a comment -

          Build libcouchbase-2.8.5-152 contains libcouchbase commit 63163ea9dee382517ec6fc0d5d97a187bce248a6 with commit message:
          CCBC-918: don't ping KV on nodes without DATA service
          https://github.com/couchbase/libcouchbase/commit/63163ea9dee382517ec6fc0d5d97a187bce248a6

          Show
          build-team Couchbase Build Team added a comment - Build libcouchbase-2.8.5-152 contains libcouchbase commit 63163ea9dee382517ec6fc0d5d97a187bce248a6 with commit message: CCBC-918 : don't ping KV on nodes without DATA service https://github.com/couchbase/libcouchbase/commit/63163ea9dee382517ec6fc0d5d97a187bce248a6
          Hide
          build-team Couchbase Build Team added a comment -

          Build couchbase-server-5.5.0-2588 contains libcouchbase commit 63163ea9dee382517ec6fc0d5d97a187bce248a6 with commit message:
          CCBC-918: don't ping KV on nodes without DATA service
          https://github.com/couchbase/libcouchbase/commit/63163ea9dee382517ec6fc0d5d97a187bce248a6

          Show
          build-team Couchbase Build Team added a comment - Build couchbase-server-5.5.0-2588 contains libcouchbase commit 63163ea9dee382517ec6fc0d5d97a187bce248a6 with commit message: CCBC-918 : don't ping KV on nodes without DATA service https://github.com/couchbase/libcouchbase/commit/63163ea9dee382517ec6fc0d5d97a187bce248a6
          Hide
          build-team Couchbase Build Team added a comment -

          Build couchbase-server-6.0.0-1061 contains libcouchbase commit 63163ea9dee382517ec6fc0d5d97a187bce248a6 with commit message:
          CCBC-918: don't ping KV on nodes without DATA service
          https://github.com/couchbase/libcouchbase/commit/63163ea9dee382517ec6fc0d5d97a187bce248a6

          Show
          build-team Couchbase Build Team added a comment - Build couchbase-server-6.0.0-1061 contains libcouchbase commit 63163ea9dee382517ec6fc0d5d97a187bce248a6 with commit message: CCBC-918 : don't ping KV on nodes without DATA service https://github.com/couchbase/libcouchbase/commit/63163ea9dee382517ec6fc0d5d97a187bce248a6

            People

            • Assignee:
              brett19 Brett Lawson
              Reporter:
              david.saadeh David Saadeh
            • 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

                  Error rendering 'com.pagerduty.jira-server-plugin:PagerDuty'. Please contact your Jira administrators.