0

I want to implement a job using the Apache Flink Statefun API and configure Kafka as a trigger. The idea is have events go into a Kafka topic, and have it then trigger a stateful function in Flink like a FaaS. Is this possible? How would it be implemented? I looked at the Kafka IO documentation but couldn't find any concrete code examples so if anyone has a simple example it would be greatly appreciated.

Baiqing
  • 1,223
  • 2
  • 9
  • 21

1 Answers1

0

That's exactly what the Kafka ingress does.

There's a complete example application in https://github.com/ververica/flink-statefun-workshop that uses Kafka.

David Anderson
  • 39,434
  • 4
  • 33
  • 60
  • Thanks! Are there any chance of a Java example? – Baiqing Apr 27 '22 at 14:21
  • I haven't seen a Java example that uses Kafka. Conceptually it fits in the same way, but if you are using embedded Java functions the details of setting up the routing will be a bit different, I believe. – David Anderson Apr 28 '22 at 18:40