Questions tagged [spring-cloud-function]

Use this tag for questions related to the Spring Cloud Function project

Spring Cloud Function is a project in a Spring Cloud portfolio of projects with the following high-level goals:

  • Promote the implementation of business logic via java.util.function.(Supplier, Function, Consumer)
  • Provide necessary deployment and runtime abstractions to ensure the same code can run in multiple environments (e.g., a web endpoint, a stream processor, or a task).
  • Support a uniform programming model across serverless providers, as well as the ability to run standalone (locally or in a PaaS).
  • Enable Spring Boot features (auto-configuration, dependency injection, metrics) on serverless providers.

Resources

See Also

255 questions
2
votes
1 answer

How to consume Kafka-events with spring-cloud-function, but only sometimes produce

I have successfully set up spring-cloud-function with kafka-streams in Kotlin and have a working prototype. I have one function that receives the events from one topic and produces another event to another topic. Here's my application.yml spring: …
Jan
  • 2,747
  • 27
  • 35
2
votes
0 answers

How to test a Spring Cloud Function using message stream

I'm currently attempting to port an existing Spring Cloud Stream app over to using Spring Cloud Function instead. When running the application, we use bindings to map from an input queue (either Kafka or IBMMQ). Messages sent on the queue are passed…
Steve
  • 2,678
  • 8
  • 40
  • 54
2
votes
1 answer

Spring Cloud Stream Function : Invoke Function via REST call and output it to a KAFKA Topic

I have simple @Bean (Java 8 Functions) which are mapped to a destination topic (-out and -in). @Bean public Function transform() { return payload -> payload.toUpperCase(); } @Bean public Consumer receive() { return…
2
votes
1 answer

Spring cloud function azure json output with datetimes

I output a POJO from an azure function written with spring cloud function which contains a datetime type. I have tried it with instant where it was treated as a POJO: "timestamp": { "seconds": 1584229103, "nanos" 0 } I tried it as an…
2
votes
1 answer

Exception: org.springframework.messaging.MessageDeliveryException: Dispatcher has no subscribers for channel

I have a sandbox for exploring newly added functions in Spring Cloud Stream, but I've faced a problem with using Function and Supplier in one Spring Cloud Stream application. In code I used examples described in docs. Firstly I added to project…
2
votes
1 answer

Understanding difference between Custom Handler and SpringBootApiGatewayRequestHandler

I'm new to Spring Cloud Function and came across it as one of best solution for developing FaaS based solution. I am specifically writing application for AWS Lambda Service which is back-end of API Gateway. I ran into very interesting problem with…
2
votes
1 answer

Cloud Kafka with spring boot gives me errors

Hey I followed a step by step guide for setting up kafka in spring boot. But now I cannot start the app. Any suggestions :) error from the log: org.springframework.beans.factory.BeanCreationException: Error creating bean with name…
2
votes
0 answers

How to unit test a spring cloud function app?

I'm trying to unit test a spring cloud function based application that has to be run on AWS lambda taking an SQS event as trigger. see this example : https://www.baeldung.com/spring-cloud-function The function runs fine on AWS lambda. But my unit…
BugHunter
  • 61
  • 1
  • 7
2
votes
0 answers

Spring Cloud Function and SQSEvent Triggered AWS Lambda Function

I'm unable to get a Spring-Cloud based AWS Lambda Function with an SQS Message trigger to work. I'm using the Spring Cloud Function AWS adapter version 2.0.1.RELEASE and attempting to deploy to the AWS EU-WEST-2 Region. My SpringBootRequestHandler…
majafri
  • 21
  • 4
2
votes
0 answers

Spring WebFlux: Testing WebClient server send events

Actually I am not even sure if it is possible to do what I want to: I am consuming an event stream (Event.class) from a Broker (MQTT) using Spring Integration and want to forward the stream to another microservice. Both services are supposed to be…
2
votes
1 answer

Azure Function with Spring Boot + Spring Cloud Function unable to locate main class

Trying to run azure-sample but encountering a "Failed to locate main class" error when a request comes in. Build project in eclipse with maven. Updated code based on this issue (or else you will get a ClassCast Exception). Running locally or…
2
votes
1 answer

Is there an integration of spring cloud function webflux + spring cloud stream with http source

I am trying to integrate spring cloud stream with spring cloud function webflux as they are deprecating spring cloud reactive streams in future releases I am trying to use spring cloud…
2
votes
1 answer

Spring Cloud Function deployed on AWS Lambda fails with NullPointerException at FunctionalSpringApplication.java:102

I have a very simple Spring Cloud Functions with the AWS adapter to run it as an AWS Lambda. The source code is available on Github: https://github.com/codependent/spring-boot-authentication-function @SpringBootApplication class…
2
votes
0 answers

Spring Cloud Function With Kinesis

I am trying to listen to data coming in AWS Kinesis Streams, through my AWS Lambda with Spring Cloud Function. I am not able to map the input coming from Kinesis to my Handler. MyHandler.java public class RequestHandler extends…
1
vote
0 answers

Using two separate binders for RabbitMQ spring cloud function

We are trying to use a single spring consumer function to connect to 2 different queues in 2 different rabbitmq instances. This doesn't seem to work. The consumer function is bound to the first binder declared in the application yaml. Config in…
1 2
3
16 17