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

https://github.com/daggerok/reactive-spring-cloud

This repository contains new reactive spring cloud example
https://github.com/daggerok/reactive-spring-cloud

httpbin reactive spring-cloud-gateway webflux

Last synced: about 2 months ago
JSON representation

This repository contains new reactive spring cloud example

Awesome Lists containing this project

README

          

= reactive-spring-cloud examples image:https://travis-ci.org/daggerok/reactive-spring-cloud.svg?branch=master["Build Status", link="https://travis-ci.org/daggerok/reactive-spring-cloud"]

//tag::content[]

This repository contains new reactive spring cloud examples.

Currently in progress.... See other repos:

- link:https://github.com/daggerok/spring-cloud-function-stream-integration[spring-cloud-function and spring-cloud-stream integration]

.gateway looks for set of RouteLocator (see gatewat config)

.build and run
[source,bash]
----
# gradle
bash ./gradlew
java -jar gateway/build/libs/*.jar

# maven
bash ./mvnw
java -jar gateway/target/*.jar
----

.test /get gateway path route
[source,bash]
----
http :8080/get 08:43:32
HTTP/1.1 200 OK
Access-Control-Allow-Credentials: true
Access-Control-Allow-Origin: *
Connection: keep-alive
Content-Length: 302
Content-Type: application/json
Date: Sat, 20 Jan 2018 06:43:39 GMT
Server: meinheld/0.6.1
Via: 1.1 vegur
X-Powered-By: Flask
X-Processed-Time: 0.000678062438965
----

.output
[source,json]
----
{
"args": {},
"headers": {
"Accept": "*/*",
"Accept-Encoding": "gzip, deflate",
"Connection": "close",
"Host": "httpbin.org",
"User-Agent": "HTTPie/0.9.9",
"X-Spring-Cloud-Gateway": "Is-F*cking-Awesome!"
},
"origin": "195.230.115.34",
"url": "http://httpbin.org/get"
}
----

links:

. link:https://www.youtube.com/watch?v=9wocKqF15B8[Spencer Gibb spring one talk]

//end::content[]