google / knative-gcp

GCP event implementations to use with Knative Eventing.
https://github.com/knative/eventing
Apache License 2.0
160 stars 74 forks source link

Unable to delete Kafka Broker, failed to delete topic #2254

Closed QuickWorkDeveloper closed 2 years ago

QuickWorkDeveloper commented 2 years ago

Describe the bug We have deployed a Kafka cluster along with all of the YAML files mentioned in the documentation at https://knative.dev/docs/eventing/broker/kafka-broker/

Furthermore, a ConfigMap has been configured which holds the reference to the Kafka cluster. Post that, we create a broker just as described in the documentation as stated below.

apiVersion: eventing.knative.dev/v1 kind: Broker metadata: name: default namespace: default annotations: eventing.knative.dev/broker.class: Kafka spec: config: apiVersion: v1 kind: ConfigMap name: kafka-broker-config namespace: knative-eventing

The broker gets established successfully and provides a broker URL that works. However, if we attempt to delete the broker, the kubectl would simply get stuck unless we patch the broker to have empty array of finalizers.

On describing the broker, we get to see the following error:

Warning InternalError 4s (x14 over 45s) broker-controller failed to delete topic knative-broker-default-default: kafka server: This most likely occurs because of a request being malformed by the client library or the message was sent to an incompatible broker. See the broker logs for more details.

Any ideas what to do?

Expected behavior The broker should delete normally.

To Reproduce Simply create a broker using the broker above and attempt to delete it with Kubectl.

Knative-GCP release version v1.1

Additional context

Knative Eventing pods

eventing-controller-5f7c968bf6-kpd4v 1/1 Running 0 5h11m eventing-kafka-channel-controller-86dd885f4d-7msss 1/1 Running 0 93m eventing-webhook-7576cf5d79-w45f2 1/1 Running 0 5h6m imc-controller-67b8f9b7b4-ds68v 1/1 Running 0 5h11m imc-dispatcher-f89df569b-m67x2 1/1 Running 0 5h11m kafka-broker-dispatcher-7b84bd8d4-d84kj 1/1 Running 0 3h34m kafka-broker-receiver-d5b447489-rb4s9 1/1 Running 0 3h34m kafka-ch-controller-644f7f994d-5pn79 1/1 Running 0 94m kafka-controller-fb6b99fb-jw95v 1/1 Running 0 3h34m kafka-controller-manager-566796d686-rxlmq 1/1 Running 0 96m kafka-sink-receiver-59687f5f9-wxqf2 1/1 Running 0 84m kafka-webhook-855486b5f7-mgl6t 1/1 Running 0 93m kafka-webhook-eventing-758b4d9cc5-ccm9n 1/1 Running 0 3h34m mt-broker-controller-77986bcb67-m8kjn 1/1 Running 0 5h11m mt-broker-filter-5f68b7cd48-kv4vj 1/1 Running 0 5h10m mt-broker-ingress-5d9ddd5655-bdpx8 1/1 Running 0 5h10m sugar-controller-58b979f478-4d4p4 1/1 Running 0 5h10m