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

vbucket seq-num parser should use ParseUInt/64

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 4.1.0
    • 4.0.0
    • secondary-index
    • Security Level: Public
    • Untriaged
    • Unknown

    Description

      Was looking at some indexer util code, and saw that it was parsing the ep-engine's vbucket-details stats output (sequence numbers and UUID's) by using strconv.Atoi(). Those are uint64's so using Atoi() incorrectly drops some bits...

      https://github.com/couchbase/indexing/blob/7dd11b7aaeefd6331d3ac75780db37e54d6bbd41/secondary/common/util.go#L525

      https://github.com/couchbase/indexing/blob/7dd11b7aaeefd6331d3ac75780db37e54d6bbd41/secondary/common/util.go#L528

      Instead, strconv.ParseUint(theString, 10, 64) should work more correctly.

      Attachments

        For Gerrit Dashboard: MB-16184
        # Subject Branch Project Status CR V

        Activity

          People

            prataprc Pratap Chakravarthy (Inactive)
            steve Steve Yen
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty