Uploaded image for project: 'Couchbase .NET client library'
  1. Couchbase .NET client library
  2. NCBC-3688

Investigate performance of a single cached key encoding

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Major
    • None
    • None
    • None
    • None
    • 3

    Description

      See comments on this patch from NCBC-3666.

      Motivation

      Previously, the Key encoding happened in the VBucketMapper when hashing the Key to get its associated VBucket ID.
      If the encoded key was too long (>250 bytes), A System exception would be thrown as the bytes don't fit in the constrained span.

      We want to check the byte length of keys passed for all KV operations that apply, and throw a Couchbase.InvalidArgumentException if the encoding fails.

      NCBC-3666 added this Length check upfront for all KV operations, but we want to investigate the performance cost of:
      1. Encoding the key twice (once in CouchbaseCollection/Operationbase, once in VBucketMapper)
      2. Encoding once in OperationBase and throwing there (fail-fast)
      3. Encoding once in VBucketMapper and throwing there (goes through Retry)

      Attachments

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

        Activity

          People

            emilien.bevierre Emilien Bevierre
            emilien.bevierre Emilien Bevierre
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty