Uploaded image for project: 'Couchbase Kubernetes'
  1. Couchbase Kubernetes
  2. K8S-1253

Helm chart always creates default bucket

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 2.0.0
    • None
    • helm
    • None

    Description

      The helm chart specifies buckets in the following way:

        buckets:
          bucket1:
            name: bucket1
            type: couchbase
            memoryQuota: 128
            replicas: 1
            evictionPolicy: fullEviction
            conflictResolution: seqno
            ioPriority: high
            compressionMode: "passive"
          bucket2:
            name: bucket2
            type: couchbase
            memoryQuota: 128
            replicas: 1
            evictionPolicy: fullEviction
            conflictResolution: seqno
            ioPriority: high
            compressionMode: "passive"
      

      The buckets object is itself a map of strings to bucket objects, with a name field to specify the bucket name.

      Within our default values.yaml, we have just the default bucket:

        # cluster buckets
        buckets:
          # The default bucket
          default:
            # Name of the bucket
            name: default
            # The type of bucket to use
            type: couchbase
            # The amount of memory that should be allocated to the bucket
            memoryQuota: 128
            # The number of bucket replicates
            replicas: 1
            # The priority when compared to other buckets
            ioPriority: high
            # The bucket eviction policy which determines behavior during expire and high mem usage
            evictionPolicy: fullEviction
            # The bucket's conflict resolution mechanism; which is to be used if a conflict occurs during Cross Data-Center Replication (XDCR). Sequence-based and timestamp-based mechanisms are supported.
            conflictResolution: seqno
            # The enable flush option denotes wether the data in the bucket can be flushed
            enableFlush: true
            # Enable Index replica specifies whether or not to enable view index replicas for this bucket.
            enableIndexReplica: false
            # data compression mode for the bucket to run in [off, passive, active]
            compressionMode: "passive"
      

      When you override the helm chart with custom values, it tries to 'merge' the custom values file and the default values.
      In the case of buckets, as this is a map and not an array, this will cause the buckets to be merged.

      The net effect of this is that even if you specify your own buckets in values.yaml, the default bucket will always be created.

      Workaround

      You can workaround this by setting the key of one of your buckets in the custom values file to be default, for example:

        buckets:
          default:
            name: bucket1
            type: couchbase
            memoryQuota: 128
            replicas: 1
            evictionPolicy: fullEviction
            conflictResolution: seqno
            ioPriority: high
            compressionMode: "passive"
          bucket2:
            name: bucket2
            type: couchbase
            memoryQuota: 128
            replicas: 1
            evictionPolicy: fullEviction
            conflictResolution: seqno
            ioPriority: high
            compressionMode: "passive"
      

      Attachments

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

        Activity

          People

            tommie Tommie McAfee (Inactive)
            matt.carabine Matt Carabine (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty