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

getIndexStats returns completion as 0 when status of index is "Ready"

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Major
    • Morpheus
    • Morpheus
    • secondary-index
    • None
    • Untriaged
    • 1
    • Unknown

    Description

      1. Create 2 node cluster both with index and query service
      2. Create a bucket ephemeral `src`
      3. Create primary index on `src`(CREATE PRIMARY INDEX on src; )
      4. query getIndexStatus

      curl -X GET -u Administrator:asdasd http://127.0.0.1:9102/getIndexStatus | jq
        % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                       Dload  Upload   Total   Spent    Left  Speed
      100   511  100   511    0     0   249k      0 --:--:-- --:--:-- --:--:--  249k
      {
        "code": "success",
        "status": [
          {
            "defnId": 15989850828353130000,
            "instId": 9154237440146929000,
            "name": "#primary",
            "bucket": "src",
            "scope": "_default",
            "collection": "_default",
            "isPrimary": true,
            "indexType": "plasma",
            "status": "Ready",
            "definition": "CREATE PRIMARY INDEX `#primary` ON `src`",
            "hosts": [
              "127.0.0.1:9001"
            ],
            "completion": 0,
            "progress": 0,
            "scheduled": false,
            "partitioned": false,
            "numPartition": 1,
            "partitionMap": {
              "127.0.0.1:9001": [
                0
              ]
            },
            "numReplica": 0,
            "indexName": "#primary",
            "replicaId": 0,
            "stale": false,
            "lastScanTime": "NA"
          }
        ]
      }

      Querying other node gives completion as 100.

      curl -X GET -u Administrator:asdasd http://127.0.0.1:9108/getIndexStatus | jq
        % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                       Dload  Upload   Total   Spent    Left  Speed
      100   515  100   515    0     0   251k      0 --:--:-- --:--:-- --:--:--  251k
      {
        "code": "success",
        "status": [
          {
            "defnId": 15989850828353130000,
            "instId": 9154237440146929000,
            "name": "#primary",
            "bucket": "src",
            "scope": "_default",
            "collection": "_default",
            "isPrimary": true,
            "indexType": "plasma",
            "status": "Ready",
            "definition": "CREATE PRIMARY INDEX `#primary` ON `src`",
            "hosts": [
              "127.0.0.1:9001"
            ],
            "completion": 100,
            "progress": 100,
            "scheduled": false,
            "partitioned": false,
            "numPartition": 1,
            "partitionMap": {
              "127.0.0.1:9001": [
                0
              ]
            },
            "numReplica": 0,
            "indexName": "#primary",
            "replicaId": 0,
            "stale": false,
            "lastScanTime": "NA"
          }
        ]
      }

      Attachments

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

        Activity

          People

            amit.kulkarni Amit Kulkarni
            ankit.prabhu Ankit Prabhu
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty