0

We have a Kafka listener consuming messages from topic. We want to make this bean as functional so we can spin up multiple instances of function using server less architecture when there is heavy load. Can anyone show me a right direction

nani21984
  • 911
  • 2
  • 13
  • 21

1 Answers1

1

Take a look at Spring Cloud Stream Function support. You can use it with a Kafka binder.

In the previous post, I tried to provide justification for our shift to a functional programming model in Spring Cloud Stream (SCSt). It’s less code, less configuration. Most importantly, though, your code is completely decoupled and independent from the internals of SCSt.

In this post, I’ll dig a little deeper and summarize the core features of our functional support, specifically around its reactive features.

Community
  • 1
  • 1
Gary Russell
  • 166,535
  • 14
  • 146
  • 179
  • I looked at SCF earlier ... and most of the examples are invoking functions via url and not by SCSt and then connect it to any serverless architecture. Struggling to make existing spring boot application as serverless which is consumed topic and process the events and emit events into different topic – nani21984 Nov 16 '19 at 18:51
  • SCSt builds on top of SCF and binds input and output topics to a function. – Gary Russell Nov 16 '19 at 18:58
  • Yeah I am able to achieve it .. invoking that function from SCSt. But I can’t get it right to invoke that function from serverless architecture. It is different from invoking vanilla or SCF which is being exposed as REST endpoint. Or may be I am not getting it right . I am using spring-2.1.4 Release. – nani21984 Nov 16 '19 at 18:59