Uploaded image for project: 'AMQ Streams'
  1. AMQ Streams
  2. ENTMQST-2099

When set to blank value for toleration Kafka cluster keeps rolling updates repeatedly

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 1.6.0.GA
    • 1.5.0.GA
    • cluster-operator
    • None
    • Hide
      • Although not entirely semantically the same, if the only key without value is used as a taint for nodes because it's rarely possible to mix a taint without value and with value, the "Exists" operation can be used instead of the "Equals" operation and blank string as below:
        apiVersion: kafka.strimzi.io/v1beta1
        kind: Kafka
        spec:
          kafka:
            template:
              pod:
                tolerations:
                  - effect: NoSchedule
                    key: kafkarole
                    operator: Exists
        
      Show
      Although not entirely semantically the same, if the only key without value is used as a taint for nodes because it's rarely possible to mix a taint without value and with value, the "Exists" operation can be used instead of the "Equals" operation and blank string as below: apiVersion: kafka.strimzi.io/v1beta1 kind: Kafka spec: kafka: template: pod: tolerations: - effect: NoSchedule key: kafkarole operator : Exists
      1. Set a blank value for toleration, please refer to the sample configuration(*1)
      2. (FYI, Reproduction is possible without using "taint" for nodes)
      3. ==> Kafka cluster keeps rolling updates repeatedly

      • When to set blank value for toleration(*1) Kafka cluster keeps rolling updates repeatedly.
      • The following debug log(*2) is output from the cluster operator. I guess, the Cluster Operator cannot distinguish between null and blank strings, and thus a diff is found repeatedly.

      (*1) toleration set to a blank value

      apiVersion: kafka.strimzi.io/v1beta1
      kind: Kafka
      spec:
        kafka:
          template:
            pod:
              tolerations:
                - effect: NoSchedule
                  key: kafkarole
                  operator: Equal 
                  value: '' # HERE
      

      (*2) Cluster Operator debug log:

       strimzi-cluster-operator-b88dc78c5-h5z7j strimzi-cluster-operator 2020-06-30 06:34:01 DEBUG StatefulSetDiff:101 - StatefulSet p02690955/my-cluster-kafka differs:
      
      {"op":"add","path":"/spec/template/spec/tolerations/0/value","value":""}
      
      strimzi-cluster-operator-b88dc78c5-h5z7j strimzi-cluster-operator 2020-06-30 06:34:01 DEBUG StatefulSetDiff:102 - Current StatefulSet path /spec/template/spec/tolerations/0/value has value
       strimzi-cluster-operator-b88dc78c5-h5z7j strimzi-cluster-operator 2020-06-30 06:34:01 DEBUG StatefulSetDiff:103 - Desired StatefulSet path /spec/template/spec/tolerations/0/value has value ""
      

              Unassigned Unassigned
              rhn-support-tyamashi Tomonari Yamashita
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: