Slide 1

Slide 1 text

Oleg Zhurakousky Olga Maciaszek-Sharma What’s new in Spring Cloud? Copyright © 2020 VMware, Inc. or its affiliates.

Slide 2

Slide 2 text

Oleg Zhurakousky Twitter: @z_oleg Olga Maciaszek-Sharma Twitter: @olga_maciaszek

Slide 3

Slide 3 text

Safe Harbor Statement The following is intended to outline the general direction of Pivotal's offerings. It is intended for information purposes only and may not be incorporated into any contract. Any information regarding pre-release of Pivotal offerings, future updates or other planned modifications is subject to ongoing evaluation by Pivotal and is subject to change. This information is provided without warranty or any kind, express or implied, and is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions regarding Pivotal's offerings. These purchasing decisions should only be based on features currently available. The development, release, and timing of any features or functionality described for Pivotal's offerings in this presentation remain at the sole discretion of Pivotal. Pivotal has no obligation to update forward looking information in this presentation. © 2020 Spring. A VMware-backed project.

Slide 4

Slide 4 text

Spring Cloud Square Spring Boot and Spring Cloud integrations for Retrofit and OkHttp. ● WebClient support for Retrofit interface clients ● Auto-configurations for Retrofit and OkHttp ● Load-balancing ● Tracing for OkHttp ● Only Retrofit annotations ● Incubator project ● Maintenance timeline - 2021.x release train

Slide 5

Slide 5 text

Spring Cloud Square

Slide 6

Slide 6 text

Spring interface clients Interface clients for within Spring Framework. ● A first-class solution in Framework replacing third-party integrations ● HTTP already present in Spring 6 milestones ○ HttpServiceProxyFactory , @HttpExchange annotation ○ Support for HttpMethod, @PathVariable, @RequestAttribute , @RequestBody, @RequestHeader , @RequestParam ○ Support for both blocking and non-blocking mode ○ Planned multipart support ● Planned RSocket interface client

Slide 7

Slide 7 text

Spring HTTP interface client

Slide 8

Slide 8 text

Spring Cloud Observability Moving out of Spring Cloud Sleuth to Micrometer 1.10 and direct instrumentation in projects ● Micrometer 1.10 Tracing with Observation API ○ Observation ○ ObservationHandler ● Planned: tracing set-up by Spring Boot 3 ● Spring Cloud Sleuth maintained for 2021.x

Slide 9

Slide 9 text

Spring Cloud Observability - Observation

Slide 10

Slide 10 text

Spring Cloud Observability - ObservationHandler

Slide 11

Slide 11 text

RSocket Reactive Streams semantics on protocol level ● Message-driven, asynchronous ● No client/ server distinction once connection is made ● 4 modes ○ Fire and Forget ○ Request/ Response ○ Request/ Stream ○ Channel

Slide 12

Slide 12 text

RSocket Reactive Streams semantics on protocol level ● Binary ● Flow control ○ Backpressure ○ Leasing ● Protocol support: ○ TCP ○ WebSockets ○ Aeron ○ HTTP/3 (QUIC)?

Slide 13

Slide 13 text

RSocket support in Spring Support in spring-messaging ● RSocketRequester fluent API ● @MessageMapping and @ConnectMapping annotated responders

Slide 14

Slide 14 text

RSocket support in Spring Support in spring-messaging ● MetadataExtractor

Slide 15

Slide 15 text

RSocket Broker A specialized distributed broker for RSocket ● Service discovery ● Load-balancing ● Fault tolerance ● Security

Slide 16

Slide 16 text

RSocket Broker RSocket Broker Service 1 Service 3 Service 2 Service 3 RSocket Broker RSocket Broker Service 1 Service 2

Slide 17

Slide 17 text

RSocket HTTP Bridge Seamless routing of HTTP requests through RSocket Broker ● POST requests ● serviceId and RSocket endpoint resolved from path ● Support for byte arrays and payload decoding ● RSocket Broker tags resolved from HTTP headers ● RSocket interaction mode resolved from URI or default configuration ● Support for RSocket Broker WellKnownKey ● Spring Cloud Gateway integration

Slide 18

Slide 18 text

Demo

Slide 19

Slide 19 text

Spring Native Support for GraalVM native images in Spring ● Initial support provided by the Spring Native project moving over to Spring 6 ● Compatibility ● Native configuration files ● AOT plugin - AOT transformations

Slide 20

Slide 20 text

Spring Cloud Native support Supported starters ● Spring Cloud Config Client ● Spring Cloud Config Server ● Spring Cloud Netflix Eureka Client ● Spring Cloud Sleuth ● Spring Cloud Function ● Spring Cloud Stream ● Spring Cloud Task ● Spring Cloud Sleuth Zipkin

Slide 21

Slide 21 text

Spring Cloud Native support Planned support ● Spring Cloud Gateway ● Spring Cloud OpenFeign ● Spring Cloud CircuitBreaker ● Spring Cloud Kubernetes ● Spring Cloud LoadBalancer

Slide 22

Slide 22 text

Spring Cloud Function Exposes Java Functions as Spring’s managed components ● Promotes implementation of business logic as functions ○ Supplier, ○ Function, ○ Consumer ● Function Composition ● Transparent Type conversion ● POJO Functions ● Reactive Support ● Deployment of packaged functions ● Adapters to serverless platforms

Slide 23

Slide 23 text

Demo

Slide 24

Slide 24 text

Spring Cloud Function Adapters Extensions to expose java functions to different invocation models ● AWS Lambda ● HTTP ● gRPC ● RSocket ● Azure ● Google Functions ● CloudEvent

Slide 25

Slide 25 text

Spring Cloud Function Adapters - gRPC Exposes user functions via gRPC ● Supports two operation modes - client & server ● 4 interaction modes (request/reply, server/client/bidirectional-streaming) ● Pluggable protobuf extension OR ● Message centric

Slide 26

Slide 26 text

Demo

Slide 27

Slide 27 text

Spring Cloud Function Adapters - RSocket Exposes user functions as RSocket endpoints ● Supports all 4 RSocket invocation models ○ Fire and Forget ○ Request/ Response ○ Request/ Stream ○ Channel

Slide 28

Slide 28 text

Demo

Slide 29

Slide 29 text

Spring Cloud Function Adapters - AWS Lambda ● Provides ability to represent simple Java Functions as AWS Lambda ● Supports many event types ● Custom Runtime ● GraalVM support via Spring Native

Slide 30

Slide 30 text

Demo

Slide 31

Slide 31 text

Spring Cloud Stream Event stream processing (ESP) is the practice of taking action on a series of data points that originate from a system that continuously creates data. https://hazelcast.com/glossary/event-stream-processing/

Slide 32

Slide 32 text

Spring Cloud Stream Framework to enable “event stream processing” applications - microservices ● Spring Boot driven ● Connects Messaging Brokers with user code using Destination Binders ● Core features ○ Partitioning ○ Consumer Groups ○ Message Headers ○ Destination provisioning ● Message centric ● Spring Cloud Function as programming model

Slide 33

Slide 33 text

Spring Cloud Stream What’s new ● Native support ● StreamBridge ● Mono Repo ● Reactive Kafka Binder ● Complete removal of annotation-based programming model

Slide 34

Slide 34 text

Demo

Slide 35

Slide 35 text

Resources ● Demo code ● Spring Cloud Square ● Spring HTTP interface clients ● Micrometer Tracing ● RSocket ● Spring support for RSocket ● RSocket Broker ● RSocket HTTP Bridge

Slide 36

Slide 36 text

Thank you © 2020 Spring. A VMware-backed project.