question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

The CustomResourceDefinition "kafkas.kafka.strimzi.io" is invalid: metadata.annotations: Too long: must have at most 262144 bytes

See original GitHub issue

With the new 0.22.0 release I am getting this error:

The CustomResourceDefinition "kafkas.kafka.strimzi.io" is invalid: metadata.annotations: Too long: must have at most 262144 bytes

When doing:

  ##strimzi_version=$(curl https://github.com/strimzi/strimzi-kafka-operator/releases/latest |  awk -F 'tag/' '{print $2}' | awk -F '"' '{print $1}' 2>/dev/null)
  oc create namespace kafka
  oc -n kafka apply --selector strimzi.io/crd-install=true -f "https://github.com/strimzi/strimzi-kafka-operator/releases/download/${strimzi_version}/strimzi-cluster-operator-${strimzi_version}.yaml"
  curl -L "https://github.com/strimzi/strimzi-kafka-operator/releases/download/${strimzi_version}/strimzi-cluster-operator-${strimzi_version}.yaml" \
  | sed 's/namespace: .*/namespace: kafka/' \
  | oc -n kafka apply -f -

Version 0.21.1 works

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:2
  • Comments:20 (9 by maintainers)

github_iconTop GitHub Comments

2reactions
scholzjcommented, May 10, 2021

Yeah, I have the same problem. kubectl apply will work again in 0.23 after we removed the older APIs.

2reactions
scholzjcommented, Mar 17, 2021

Yeah, this is not a bug in Strimzi. kubectl apply adds the original resource to annotations and annotations have limited size. So it cannot handle the Kafka CRD which is too big (because of the migration to v1beta2 which is needed because of the migration to CRD v1). You have to use kubectl create / kubectl replace.

Read more comments on GitHub >

github_iconTop Results From Across the Web

040-Crd-kafka.yaml file is missing the sequence and is failing
The CustomResourceDefinition "kafkas.kafka.strimzi.io" is invalid: metadata.annotations: Too long: must have at most 262144 bytes.
Read more >
Kubectl Install CRD Failed — Annotations Too Long - Medium
The CustomResourceDefinition "prometheuses.monitoring.coreos.com" is invalid: metadata.annotations: Too long: must have at most 262144 bytes ...
Read more >
Large CRDs go over size limits (e.g. those with embedded ...
The CustomResourceDefinition "kafkas.kafka.strimzi.io" is invalid: metadata.annotations: Too long: must have at most 262144 bytes ...
Read more >
Re: Adding annotations and limits of kafka connect created pods
i have the following configuration: apiVersion: kafka.strimzi.io/v1beta2. kind: KafkaConnect. metadata: name: my-connect-cluster. namespace: kafka.
Read more >
"io.strimzi.operator.cluster.model.InvalidResourceException ...
model.InvalidResourceException: Kafka namespace-name/my-cluster has invalid spec.kafka.config: inter.broker.protocol.version has value '3' which ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found