Knative Eventing KafkaSource issue

50 views
Skip to first unread message

Luca Celardo

unread,
Jan 24, 2020, 12:38:35 PM1/24/20
to Knative Users

Hi guys,


I’ve got an issue with Knative Eventing and I would like to have your help as I am fresh about it.

I am using Knative v0.10.0, minikube v1.5.2, Docker v19.03.1 and Kafka 2.3.1 (used as the source of events). I developed a kafka producer and a kafka consumer using Kafka Java client APIs and Spring Boot. They work in pipeline so I have a CronJobSource that wakes up my producer each X minutes, the producer sends some events to a Kafka Topic, then I configured a KafkaSource that listen to that topic and should wakes up the consumer. Actually, the KafkaSource does nothing even if everything seems to be configured well, I tried to log KafkaSource, but it has no errors or succeed logs. Both producer and consumer can work well if I wake up them manually without passing through KafkaSource.


This is my KafkaSource yaml file configuration:

 

apiVersion: sources.eventing.knative.dev/v1alpha1

kind
: KafkaSource

metadata
:

  name
: ods-datamartextractor-kafka-source

spec
:

  consumerGroup
: ods-dataconverter-consumer-group-id

  bootstrapServers
: my-cluster-kafka-bootstrap.kafka:9092

  topics
: datamartextractor-topic

  sink
:

   
ref:

        apiVersion
: serving.knative.dev/v1

        kind
: Service

        name
: ods-dataconverter-service


Thank you,

Luca

ssethupathi

unread,
Feb 8, 2020, 4:49:50 AM2/8/20
to Knative Users
Any chance you are not passing a valid json as your data payload? I've managed to get a simple KafkaSource working and I observed, if it's not a valid json payload, nothing happens. I've got a valid json payload successfully received in my sink service.

Hope this helps.

Sethu
Reply all
Reply to author
Forward
0 new messages