An open API service indexing awesome lists of open source software.

https://github.com/techprimers/spring-cloud-function-example

Spring Cloud Function example
https://github.com/techprimers/spring-cloud-function-example

serverless serverless-framework serverless-functions spring spring-boot spring-cloud-function

Last synced: 2 months ago
JSON representation

Spring Cloud Function example

Awesome Lists containing this project

README

        

# Spring Cloud Function example

## Exposed Functions as Endpoints
- *Supplier* - `/supply` - returns an output

```
curl -H 'Content-Type: text/plain' http://localhost:8080/supply
Hello Youtube⏎

```

- *Consumer* - `/consume` - expects an input

```
curl -H 'Content-Type: text/plain' http://localhost:8080/consume -d 'Hello TechPrimer'
```

- *Function* - `/function` - expects an input and output
```
curl -H 'Content-Type: text/plain' http://localhost:8080/function -d 'Hello TechPrimer'
Hello TechPrimer⏎
```

- *Function* - `/hello` - expects an input and output
```
curl -H 'Content-Type: text/plain' http://localhost:8080/hello -d 'TechPrimers'
Hello TechPrimers⏎
```