SlideShare a Scribd company logo
1 of 32
Download to read offline
Winning the Lottery
with Spring
A Micro Microservices Case Study for Nederlandse Loterij
About Me
 Joris Kuipers
 @jkuipers
 CTO, hands-on architect and
fly-by-night Spring trainer
@ Trifork Amsterdam
Setting The Stage
“When we are born we cry that we are come to this great stage of fools.”
― William Shakespeare
Introduction
 Integration platform for Nederlandse Loterij
 Expose many (mostly new) backends to clients by
providing APIs based on custom domain model
 Encapsulate backend details
 Facilitate future replacement
 Serves ca. 2 million users
 peaks during state lottery draws and big soccer games
Architecture
 Separate domains
(verticals)
and service types
(horizontals)
 Verticals:
specific games,
subscriptions, players, …
Project Setup
 Every service is Spring Boot / Cloud app
 Running on AWS EKS (Kubernetes)
 Blocking HTTP for inter-service communication
 Too early for reactive
 Mono-repo using Gradle build
 More services (~30) than teams (1)
 Easy to have shared libs
Chapter 1: Autoconfiguration
for the people
“I like the elitism of the art world.
I think art for the people is a terrible idea.”
― John Waters
Spring Boot Autoconfiguration
 Spring Boot’s main and most visible feature
 Used extensively within the framework
 But not restricted to Spring Boot itself
 Conditional configuration classes automatically
applied
 Listed in META-INF/spring.factories
Custom Autoconfiguration
Benefits of using autoconfiguration yourself:
 Encapsulation
 Dynamic configuration
 Conditions
 Overridable defaults
 Easy for clients
 Esp. when providing @ConfigurationProperties!
Autoconfiguration Examples:
HTTP Client Config
 Apache Component HTTP client
 sane defaults for timeouts, connections (# and TTL), etc.
plus @ConfigurationProperties to override those
 RestTemplateCustomizers
 Ensure HTTP client is used
 Configure request/response logging, incl.
BufferingClientHttpRequestFactory wrapper
Discover Configuration Options
@ConfigurationProperties allows IDE auto-completion
 Discover available options
 Inline documentation incl. defaults
 Enum / boolean values also auto-complete!
Autoconfiguration Examples:
Client library for 3rd-party service
 Sets up client for calls to external service, adds:
 Custom JSON marshalling config
 Error handling
 Often involves parsing JSON response
 Authentication (OAuth bearer token, basic auth, …)
 Might overlap with error handling:
Spring Retry to redo request after refreshing expired token
Chapter 2: Observability for Messaging
“To acquire knowledge, one must study;
but to acquire wisdom, one must observe.”
― Marilyn vos Savant
Distributed Tracing
 Spring Sleuth allows distribute tracing
 Propagating correlation ID per logical request
 Called Trace ID
 Instruments many Spring components out of the box
Sleuth and SQS
 Spring Cloud AWS for SQS integration
 Template for sending, listener container for receiving
 Added Sleuth integration ourselves
 Tracing info added as message headers
 Allows for two things:
 Correlate async logging as part of regular flow
 Admin tool to link error logs for dead-lettered messages
Async Logging Correlation
Example for single trace ID
 Blocking: player-experience -> ~-process -> ~- system
 Async: player-process -> marketing-system
Dealing with Dead Lettering
 Messages failing repeatedly go to dead letter queue
 Problem: what do you do with them?
 Answer: it depends…
Dealing with Dead Lettering
 Have to understand cause behind failure
 Bug: fix it, retry unless message itself is broken
 Unavailable back-end: wait until available & retry
 Data consistency problem: fix it first, then it depends…
 …
 Also, ensure idempotent message handlers as much
as possible!
DLQ Admin Tool
Built a tool to allow customer* to manage this
 Overview of DLQs with # of messages
 Trace logging per message
 Move (retry) or delete individual messages
 Move all messages back from a DLQ
* We reserve pruning to our operations personnel ☺
Single click to related logging
Chapter 3: Spring Cloud Netflix
“You only grow by coming to the end of something and
by beginning something else.”
― John Irving, The World According to Garp
Spring Cloud Netflix
 Part of the start of Spring Cloud
 Allowed Netflix OSS stack to be used with Spring Boot
 Eureka, Ribbon, Hystrix, Zuul, …
 Netflix stopped maintaining most of those libs
 Spring support announced to stop as well,
alternatives provided
Our Spring Cloud Netflix Usage
 Ribbon
 For service discovery & client-side load balancing
 Moved to server-side load balancing
 Zuul
 For both inter-service proxies and some proxying to 3rd parties
 Hystrix
 Circuit breaking
 Bulk heading, esp. to prevent all request-handling threads
from blocking on downstream I/O
Replacing Zuul: inter-service proxies
 Looked at Spring Cloud Gateway, but not designed
to be embedded
 Simple solution: don’t use proxying anymore
Replacing Zuul: 3rd party proxies
 Still needed solution for other proxies
 We use Spring Cloud Gateway MVC
 This is NOT Spring Cloud Gateway!
 Rather a simple RestTemplate wrapper with
Spring-MVC integration for building proxies
 Reactive version exists as well
Spring Cloud Gateway MVC
 ProxyExchange passed to controller method
 Allows for adding headers & query params, changing path and
making actual request
 Configure default and “sensitive” headers (not copied)
 Sensitive applies to both request and response
 Should always include host!
spring.cloud.gateway.proxy.sensitive=authorization,cookie,host
spring.cloud.gateway.proxy.headers.x-api-key=${subscription-api.key}
@RequestMapping(SubsMgmtProxyController.PATH_PREFIX)
public class SubsMgmtProxyController extends AbstractProxyController {
static final String PATH_PREFIX = "/subscription-mgmt-experience";
…
@RequestMapping(path = "/**", method = {GET, POST})
ResponseEntity<?> proxyOperation(HttpServletRequest request,
@RequestParam Map<String, String> params,
ProxyExchange<byte[]> proxy) {
Player player = determinePlayerId(request, params);
ProxyExchange<byte[]> proxyWithUri = proxy
.headers(new ServletServerHttpRequest(request).getHeaders())
.uri(subsUrl + proxy.path(PATH_PREFIX) + "/" + player.id + queryParams());
return "GET".equals(request.getMethod()) ? proxyWithUri.get()
: proxyWithUri.post();
}
// can be combined with more specific, regular request mapping methods
…
}
Our URI prefix,
which should be stripped
Proxy all GETs & POSTs
without specific mapping
Copy non-sensitive headers
Base URL + stripped path +
custom path segment + query
params
Perform actual proxy call
Replacing Hystrix
 Circuit breaking: use Resilience4J instead
 Didn’t like bulk heading as solution to prevent
running out of request handling threads
 Solution: use additional Tomcat connector on
separate port with custom thread pool
 Point Kubernetes liveness/readiness endpoints to that
Custom Tomcat Connector
@Configuration
@EnableConfigurationProperties(HealthConnectorProperties.class)
public class TomcatAutoConfiguration {
@Bean
WebServerFactoryCustomizer<TomcatServletWebServerFactory>
tcHealthConnectorCustomizer(HealthConnectorProperties connector) {
return server -> {
Connector healthConnector = new Connector();
healthConnector.setPort(connector.getPort());
AbstractProtocol protocol = (AbstractProtocol) healthConnector.getProtocolHandler();
protocol.setMinSpareThreads(connector.getMinThreads());
protocol.setMaxThreads(connector.getMaxThreads());
server.addAdditionalTomcatConnectors(healthConnector);
};
}
}
probes:
liveness:
enabled: false
path: /actuator/health/liveness
port: 8888
readiness:
enabled: false
path: /actuator/health/readiness
port: 8888
Conclusion
 Use what the frameworks provide you with
 Don’t be afraid to extend them
 Build your own tools to support your system
 Know what’s out there, know what’s supported
 Follow me to Q&A for questions & discussions!

More Related Content

What's hot

Non blocking io with netty
Non blocking io with nettyNon blocking io with netty
Non blocking io with nettyZauber
 
Spring Boot on Amazon Web Services with Spring Cloud AWS
Spring Boot on Amazon Web Services with Spring Cloud AWSSpring Boot on Amazon Web Services with Spring Cloud AWS
Spring Boot on Amazon Web Services with Spring Cloud AWSVMware Tanzu
 
Api gateway in microservices
Api gateway in microservicesApi gateway in microservices
Api gateway in microservicesKunal Hire
 
Spring Native and Spring AOT
Spring Native and Spring AOTSpring Native and Spring AOT
Spring Native and Spring AOTVMware Tanzu
 
Reverse proxies & Inconsistency
Reverse proxies & InconsistencyReverse proxies & Inconsistency
Reverse proxies & InconsistencyGreenD0g
 
Swagger / Quick Start Guide
Swagger / Quick Start GuideSwagger / Quick Start Guide
Swagger / Quick Start GuideAndrii Gakhov
 
Introduction to Resilience4j
Introduction to Resilience4jIntroduction to Resilience4j
Introduction to Resilience4jKnoldus Inc.
 
AMSI: How Windows 10 Plans to Stop Script-Based Attacks and How Well It Does It
AMSI: How Windows 10 Plans to Stop Script-Based Attacks and How Well It Does ItAMSI: How Windows 10 Plans to Stop Script-Based Attacks and How Well It Does It
AMSI: How Windows 10 Plans to Stop Script-Based Attacks and How Well It Does ItNikhil Mittal
 
Spring Framework - Spring Security
Spring Framework - Spring SecuritySpring Framework - Spring Security
Spring Framework - Spring SecurityDzmitry Naskou
 
Seccomp Profiles and you: A practical guide.
Seccomp Profiles and you: A practical guide.Seccomp Profiles and you: A practical guide.
Seccomp Profiles and you: A practical guide.Duffie Cooley
 
Solve cross cutting concerns with aspect oriented programming (aop)
Solve cross cutting concerns with aspect oriented programming (aop)Solve cross cutting concerns with aspect oriented programming (aop)
Solve cross cutting concerns with aspect oriented programming (aop)Siva Prasad Rao Janapati
 
SIngle Sign On with Keycloak
SIngle Sign On with KeycloakSIngle Sign On with Keycloak
SIngle Sign On with KeycloakJulien Pivotto
 
Cilium + Istio with Gloo Mesh
Cilium + Istio with Gloo MeshCilium + Istio with Gloo Mesh
Cilium + Istio with Gloo MeshChristian Posta
 
Token, token... From SAML to OIDC
Token, token... From SAML to OIDCToken, token... From SAML to OIDC
Token, token... From SAML to OIDCShiu-Fun Poon
 
Presentation of framework Angular
Presentation of framework AngularPresentation of framework Angular
Presentation of framework AngularLhouceine OUHAMZA
 
Javascript ES6 generators
Javascript ES6 generatorsJavascript ES6 generators
Javascript ES6 generatorsRamesh Nair
 
Hearts Of Darkness - a Spring DevOps Apocalypse
Hearts Of Darkness - a Spring DevOps ApocalypseHearts Of Darkness - a Spring DevOps Apocalypse
Hearts Of Darkness - a Spring DevOps ApocalypseJoris Kuipers
 
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교 및 구축 방법
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교  및 구축 방법[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교  및 구축 방법
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교 및 구축 방법Open Source Consulting
 

What's hot (20)

Non blocking io with netty
Non blocking io with nettyNon blocking io with netty
Non blocking io with netty
 
Spring Security 3
Spring Security 3Spring Security 3
Spring Security 3
 
Spring Boot on Amazon Web Services with Spring Cloud AWS
Spring Boot on Amazon Web Services with Spring Cloud AWSSpring Boot on Amazon Web Services with Spring Cloud AWS
Spring Boot on Amazon Web Services with Spring Cloud AWS
 
Api gateway in microservices
Api gateway in microservicesApi gateway in microservices
Api gateway in microservices
 
Spring Native and Spring AOT
Spring Native and Spring AOTSpring Native and Spring AOT
Spring Native and Spring AOT
 
Reverse proxies & Inconsistency
Reverse proxies & InconsistencyReverse proxies & Inconsistency
Reverse proxies & Inconsistency
 
Swagger / Quick Start Guide
Swagger / Quick Start GuideSwagger / Quick Start Guide
Swagger / Quick Start Guide
 
Introduction to Resilience4j
Introduction to Resilience4jIntroduction to Resilience4j
Introduction to Resilience4j
 
AMSI: How Windows 10 Plans to Stop Script-Based Attacks and How Well It Does It
AMSI: How Windows 10 Plans to Stop Script-Based Attacks and How Well It Does ItAMSI: How Windows 10 Plans to Stop Script-Based Attacks and How Well It Does It
AMSI: How Windows 10 Plans to Stop Script-Based Attacks and How Well It Does It
 
Spring Framework - Spring Security
Spring Framework - Spring SecuritySpring Framework - Spring Security
Spring Framework - Spring Security
 
Seccomp Profiles and you: A practical guide.
Seccomp Profiles and you: A practical guide.Seccomp Profiles and you: A practical guide.
Seccomp Profiles and you: A practical guide.
 
Solve cross cutting concerns with aspect oriented programming (aop)
Solve cross cutting concerns with aspect oriented programming (aop)Solve cross cutting concerns with aspect oriented programming (aop)
Solve cross cutting concerns with aspect oriented programming (aop)
 
SIngle Sign On with Keycloak
SIngle Sign On with KeycloakSIngle Sign On with Keycloak
SIngle Sign On with Keycloak
 
Cilium + Istio with Gloo Mesh
Cilium + Istio with Gloo MeshCilium + Istio with Gloo Mesh
Cilium + Istio with Gloo Mesh
 
Token, token... From SAML to OIDC
Token, token... From SAML to OIDCToken, token... From SAML to OIDC
Token, token... From SAML to OIDC
 
Hibernate jpa
Hibernate jpaHibernate jpa
Hibernate jpa
 
Presentation of framework Angular
Presentation of framework AngularPresentation of framework Angular
Presentation of framework Angular
 
Javascript ES6 generators
Javascript ES6 generatorsJavascript ES6 generators
Javascript ES6 generators
 
Hearts Of Darkness - a Spring DevOps Apocalypse
Hearts Of Darkness - a Spring DevOps ApocalypseHearts Of Darkness - a Spring DevOps Apocalypse
Hearts Of Darkness - a Spring DevOps Apocalypse
 
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교 및 구축 방법
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교  및 구축 방법[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교  및 구축 방법
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교 및 구축 방법
 

Similar to Winning the Lottery with Spring: A Microservices Case Study for the Dutch Lotteries

Android application architecture
Android application architectureAndroid application architecture
Android application architectureRomain Rochegude
 
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio TavillaOpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio TavillaLorenzo Carnevale
 
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio TavillaOpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio TavillaLorenzo Carnevale
 
Our way to microservices
Our way to microservicesOur way to microservices
Our way to microservicesAndi Pangeran
 
Splunk Conf 2014 - Getting the message
Splunk Conf 2014 - Getting the messageSplunk Conf 2014 - Getting the message
Splunk Conf 2014 - Getting the messageDamien Dallimore
 
A guide through the Azure Messaging services - Update Conference
A guide through the Azure Messaging services - Update ConferenceA guide through the Azure Messaging services - Update Conference
A guide through the Azure Messaging services - Update ConferenceEldert Grootenboer
 
Node.js Workshop - Sela SDP 2015
Node.js Workshop  - Sela SDP 2015Node.js Workshop  - Sela SDP 2015
Node.js Workshop - Sela SDP 2015Nir Noy
 
Networked APIs with swift
Networked APIs with swiftNetworked APIs with swift
Networked APIs with swiftTim Burks
 
Do you know what your drupal is doing? Observe it!
Do you know what your drupal is doing? Observe it!Do you know what your drupal is doing? Observe it!
Do you know what your drupal is doing? Observe it!Luca Lusso
 
Apachecon 2009
Apachecon 2009Apachecon 2009
Apachecon 2009deepalk
 
Building a Reactive System with Akka - Workshop @ O'Reilly SAConf NYC
Building a Reactive System with Akka - Workshop @ O'Reilly SAConf NYCBuilding a Reactive System with Akka - Workshop @ O'Reilly SAConf NYC
Building a Reactive System with Akka - Workshop @ O'Reilly SAConf NYCKonrad Malawski
 
Interoperability Fundamentals: SWORD 2
Interoperability Fundamentals: SWORD 2Interoperability Fundamentals: SWORD 2
Interoperability Fundamentals: SWORD 2Adrian Stevenson
 
Schema Evolution for Resilient Data microservices
Schema Evolution for Resilient Data microservicesSchema Evolution for Resilient Data microservices
Schema Evolution for Resilient Data microservicesVinícius Carvalho
 
Aceu2009 Apache Synapse Events
Aceu2009 Apache Synapse EventsAceu2009 Apache Synapse Events
Aceu2009 Apache Synapse Eventsguest60ed0b
 
Elements for an iOS Backend
Elements for an iOS BackendElements for an iOS Backend
Elements for an iOS BackendLaurent Cerveau
 

Similar to Winning the Lottery with Spring: A Microservices Case Study for the Dutch Lotteries (20)

Axis2 Landscape
Axis2 LandscapeAxis2 Landscape
Axis2 Landscape
 
Android application architecture
Android application architectureAndroid application architecture
Android application architecture
 
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio TavillaOpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (kilo) by Lorenzo Carnevale and Silvio Tavilla
 
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio TavillaOpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio Tavilla
OpenStack Identity - Keystone (liberty) by Lorenzo Carnevale and Silvio Tavilla
 
Our way to microservices
Our way to microservicesOur way to microservices
Our way to microservices
 
Splunk Conf 2014 - Getting the message
Splunk Conf 2014 - Getting the messageSplunk Conf 2014 - Getting the message
Splunk Conf 2014 - Getting the message
 
Intro to Azure Service Bus
Intro to Azure Service BusIntro to Azure Service Bus
Intro to Azure Service Bus
 
A guide through the Azure Messaging services - Update Conference
A guide through the Azure Messaging services - Update ConferenceA guide through the Azure Messaging services - Update Conference
A guide through the Azure Messaging services - Update Conference
 
Node.js Workshop - Sela SDP 2015
Node.js Workshop  - Sela SDP 2015Node.js Workshop  - Sela SDP 2015
Node.js Workshop - Sela SDP 2015
 
Networked APIs with swift
Networked APIs with swiftNetworked APIs with swift
Networked APIs with swift
 
Web Service
Web ServiceWeb Service
Web Service
 
Do you know what your drupal is doing? Observe it!
Do you know what your drupal is doing? Observe it!Do you know what your drupal is doing? Observe it!
Do you know what your drupal is doing? Observe it!
 
Serverless computing
Serverless computingServerless computing
Serverless computing
 
Apachecon 2009
Apachecon 2009Apachecon 2009
Apachecon 2009
 
Building a Reactive System with Akka - Workshop @ O'Reilly SAConf NYC
Building a Reactive System with Akka - Workshop @ O'Reilly SAConf NYCBuilding a Reactive System with Akka - Workshop @ O'Reilly SAConf NYC
Building a Reactive System with Akka - Workshop @ O'Reilly SAConf NYC
 
Interoperability Fundamentals: SWORD 2
Interoperability Fundamentals: SWORD 2Interoperability Fundamentals: SWORD 2
Interoperability Fundamentals: SWORD 2
 
Schema Evolution for Resilient Data microservices
Schema Evolution for Resilient Data microservicesSchema Evolution for Resilient Data microservices
Schema Evolution for Resilient Data microservices
 
Aceu2009 Apache Synapse Events
Aceu2009 Apache Synapse EventsAceu2009 Apache Synapse Events
Aceu2009 Apache Synapse Events
 
Micronaut brainbit
Micronaut brainbitMicronaut brainbit
Micronaut brainbit
 
Elements for an iOS Backend
Elements for an iOS BackendElements for an iOS Backend
Elements for an iOS Backend
 

More from VMware Tanzu

What AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About ItWhat AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About ItVMware Tanzu
 
Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023VMware Tanzu
 
Enhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at ScaleEnhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at ScaleVMware Tanzu
 
Spring Update | July 2023
Spring Update | July 2023Spring Update | July 2023
Spring Update | July 2023VMware Tanzu
 
Platforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a ProductPlatforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a ProductVMware Tanzu
 
Building Cloud Ready Apps
Building Cloud Ready AppsBuilding Cloud Ready Apps
Building Cloud Ready AppsVMware Tanzu
 
Spring Boot 3 And Beyond
Spring Boot 3 And BeyondSpring Boot 3 And Beyond
Spring Boot 3 And BeyondVMware Tanzu
 
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdfSpring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdfVMware Tanzu
 
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023VMware Tanzu
 
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023VMware Tanzu
 
tanzu_developer_connect.pptx
tanzu_developer_connect.pptxtanzu_developer_connect.pptx
tanzu_developer_connect.pptxVMware Tanzu
 
Tanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - FrenchTanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - FrenchVMware Tanzu
 
Tanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - EnglishTanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - EnglishVMware Tanzu
 
Virtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - EnglishVirtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - EnglishVMware Tanzu
 
Tanzu Developer Connect - French
Tanzu Developer Connect - FrenchTanzu Developer Connect - French
Tanzu Developer Connect - FrenchVMware Tanzu
 
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023VMware Tanzu
 
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring BootSpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring BootVMware Tanzu
 
SpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software EngineerSpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software EngineerVMware Tanzu
 
SpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs PracticeSpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs PracticeVMware Tanzu
 
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense SolutionsSpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense SolutionsVMware Tanzu
 

More from VMware Tanzu (20)

What AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About ItWhat AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About It
 
Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023
 
Enhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at ScaleEnhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at Scale
 
Spring Update | July 2023
Spring Update | July 2023Spring Update | July 2023
Spring Update | July 2023
 
Platforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a ProductPlatforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a Product
 
Building Cloud Ready Apps
Building Cloud Ready AppsBuilding Cloud Ready Apps
Building Cloud Ready Apps
 
Spring Boot 3 And Beyond
Spring Boot 3 And BeyondSpring Boot 3 And Beyond
Spring Boot 3 And Beyond
 
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdfSpring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
 
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
 
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
 
tanzu_developer_connect.pptx
tanzu_developer_connect.pptxtanzu_developer_connect.pptx
tanzu_developer_connect.pptx
 
Tanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - FrenchTanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - French
 
Tanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - EnglishTanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - English
 
Virtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - EnglishVirtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - English
 
Tanzu Developer Connect - French
Tanzu Developer Connect - FrenchTanzu Developer Connect - French
Tanzu Developer Connect - French
 
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
 
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring BootSpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
 
SpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software EngineerSpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software Engineer
 
SpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs PracticeSpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs Practice
 
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense SolutionsSpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
 

Recently uploaded

办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样umasea
 
React Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaReact Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaHanief Utama
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfAlina Yurenko
 
PREDICTING RIVER WATER QUALITY ppt presentation
PREDICTING  RIVER  WATER QUALITY  ppt presentationPREDICTING  RIVER  WATER QUALITY  ppt presentation
PREDICTING RIVER WATER QUALITY ppt presentationvaddepallysandeep122
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Matt Ray
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEOrtus Solutions, Corp
 
英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作qr0udbr0
 
What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...Technogeeks
 
Buds n Tech IT Solutions: Top-Notch Web Services in Noida
Buds n Tech IT Solutions: Top-Notch Web Services in NoidaBuds n Tech IT Solutions: Top-Notch Web Services in Noida
Buds n Tech IT Solutions: Top-Notch Web Services in Noidabntitsolutionsrishis
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfFerryKemperman
 
Cyber security and its impact on E commerce
Cyber security and its impact on E commerceCyber security and its impact on E commerce
Cyber security and its impact on E commercemanigoyal112
 
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Angel Borroy López
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEEVICTOR MAESTRE RAMIREZ
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Natan Silnitsky
 
Implementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureImplementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureDinusha Kumarasiri
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmSujith Sukumaran
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based projectAnoyGreter
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Hr365.us smith
 
What are the key points to focus on before starting to learn ETL Development....
What are the key points to focus on before starting to learn ETL Development....What are the key points to focus on before starting to learn ETL Development....
What are the key points to focus on before starting to learn ETL Development....kzayra69
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 

Recently uploaded (20)

办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
 
React Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaReact Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief Utama
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
 
PREDICTING RIVER WATER QUALITY ppt presentation
PREDICTING  RIVER  WATER QUALITY  ppt presentationPREDICTING  RIVER  WATER QUALITY  ppt presentation
PREDICTING RIVER WATER QUALITY ppt presentation
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
 
英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作
 
What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...
 
Buds n Tech IT Solutions: Top-Notch Web Services in Noida
Buds n Tech IT Solutions: Top-Notch Web Services in NoidaBuds n Tech IT Solutions: Top-Notch Web Services in Noida
Buds n Tech IT Solutions: Top-Notch Web Services in Noida
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdf
 
Cyber security and its impact on E commerce
Cyber security and its impact on E commerceCyber security and its impact on E commerce
Cyber security and its impact on E commerce
 
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEE
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
 
Implementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureImplementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with Azure
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalm
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based project
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)
 
What are the key points to focus on before starting to learn ETL Development....
What are the key points to focus on before starting to learn ETL Development....What are the key points to focus on before starting to learn ETL Development....
What are the key points to focus on before starting to learn ETL Development....
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 

Winning the Lottery with Spring: A Microservices Case Study for the Dutch Lotteries

  • 1. Winning the Lottery with Spring A Micro Microservices Case Study for Nederlandse Loterij
  • 2. About Me  Joris Kuipers  @jkuipers  CTO, hands-on architect and fly-by-night Spring trainer @ Trifork Amsterdam
  • 3. Setting The Stage “When we are born we cry that we are come to this great stage of fools.” ― William Shakespeare
  • 4. Introduction  Integration platform for Nederlandse Loterij  Expose many (mostly new) backends to clients by providing APIs based on custom domain model  Encapsulate backend details  Facilitate future replacement  Serves ca. 2 million users  peaks during state lottery draws and big soccer games
  • 5. Architecture  Separate domains (verticals) and service types (horizontals)  Verticals: specific games, subscriptions, players, …
  • 6. Project Setup  Every service is Spring Boot / Cloud app  Running on AWS EKS (Kubernetes)  Blocking HTTP for inter-service communication  Too early for reactive  Mono-repo using Gradle build  More services (~30) than teams (1)  Easy to have shared libs
  • 7. Chapter 1: Autoconfiguration for the people “I like the elitism of the art world. I think art for the people is a terrible idea.” ― John Waters
  • 8. Spring Boot Autoconfiguration  Spring Boot’s main and most visible feature  Used extensively within the framework  But not restricted to Spring Boot itself  Conditional configuration classes automatically applied  Listed in META-INF/spring.factories
  • 9. Custom Autoconfiguration Benefits of using autoconfiguration yourself:  Encapsulation  Dynamic configuration  Conditions  Overridable defaults  Easy for clients  Esp. when providing @ConfigurationProperties!
  • 10. Autoconfiguration Examples: HTTP Client Config  Apache Component HTTP client  sane defaults for timeouts, connections (# and TTL), etc. plus @ConfigurationProperties to override those  RestTemplateCustomizers  Ensure HTTP client is used  Configure request/response logging, incl. BufferingClientHttpRequestFactory wrapper
  • 11. Discover Configuration Options @ConfigurationProperties allows IDE auto-completion  Discover available options  Inline documentation incl. defaults  Enum / boolean values also auto-complete!
  • 12. Autoconfiguration Examples: Client library for 3rd-party service  Sets up client for calls to external service, adds:  Custom JSON marshalling config  Error handling  Often involves parsing JSON response  Authentication (OAuth bearer token, basic auth, …)  Might overlap with error handling: Spring Retry to redo request after refreshing expired token
  • 13. Chapter 2: Observability for Messaging “To acquire knowledge, one must study; but to acquire wisdom, one must observe.” ― Marilyn vos Savant
  • 14. Distributed Tracing  Spring Sleuth allows distribute tracing  Propagating correlation ID per logical request  Called Trace ID  Instruments many Spring components out of the box
  • 15. Sleuth and SQS  Spring Cloud AWS for SQS integration  Template for sending, listener container for receiving  Added Sleuth integration ourselves  Tracing info added as message headers  Allows for two things:  Correlate async logging as part of regular flow  Admin tool to link error logs for dead-lettered messages
  • 16. Async Logging Correlation Example for single trace ID  Blocking: player-experience -> ~-process -> ~- system  Async: player-process -> marketing-system
  • 17. Dealing with Dead Lettering  Messages failing repeatedly go to dead letter queue  Problem: what do you do with them?  Answer: it depends…
  • 18. Dealing with Dead Lettering  Have to understand cause behind failure  Bug: fix it, retry unless message itself is broken  Unavailable back-end: wait until available & retry  Data consistency problem: fix it first, then it depends…  …  Also, ensure idempotent message handlers as much as possible!
  • 19. DLQ Admin Tool Built a tool to allow customer* to manage this  Overview of DLQs with # of messages  Trace logging per message  Move (retry) or delete individual messages  Move all messages back from a DLQ * We reserve pruning to our operations personnel ☺
  • 20.
  • 21.
  • 22. Single click to related logging
  • 23. Chapter 3: Spring Cloud Netflix “You only grow by coming to the end of something and by beginning something else.” ― John Irving, The World According to Garp
  • 24. Spring Cloud Netflix  Part of the start of Spring Cloud  Allowed Netflix OSS stack to be used with Spring Boot  Eureka, Ribbon, Hystrix, Zuul, …  Netflix stopped maintaining most of those libs  Spring support announced to stop as well, alternatives provided
  • 25. Our Spring Cloud Netflix Usage  Ribbon  For service discovery & client-side load balancing  Moved to server-side load balancing  Zuul  For both inter-service proxies and some proxying to 3rd parties  Hystrix  Circuit breaking  Bulk heading, esp. to prevent all request-handling threads from blocking on downstream I/O
  • 26. Replacing Zuul: inter-service proxies  Looked at Spring Cloud Gateway, but not designed to be embedded  Simple solution: don’t use proxying anymore
  • 27. Replacing Zuul: 3rd party proxies  Still needed solution for other proxies  We use Spring Cloud Gateway MVC  This is NOT Spring Cloud Gateway!  Rather a simple RestTemplate wrapper with Spring-MVC integration for building proxies  Reactive version exists as well
  • 28. Spring Cloud Gateway MVC  ProxyExchange passed to controller method  Allows for adding headers & query params, changing path and making actual request  Configure default and “sensitive” headers (not copied)  Sensitive applies to both request and response  Should always include host! spring.cloud.gateway.proxy.sensitive=authorization,cookie,host spring.cloud.gateway.proxy.headers.x-api-key=${subscription-api.key}
  • 29. @RequestMapping(SubsMgmtProxyController.PATH_PREFIX) public class SubsMgmtProxyController extends AbstractProxyController { static final String PATH_PREFIX = "/subscription-mgmt-experience"; … @RequestMapping(path = "/**", method = {GET, POST}) ResponseEntity<?> proxyOperation(HttpServletRequest request, @RequestParam Map<String, String> params, ProxyExchange<byte[]> proxy) { Player player = determinePlayerId(request, params); ProxyExchange<byte[]> proxyWithUri = proxy .headers(new ServletServerHttpRequest(request).getHeaders()) .uri(subsUrl + proxy.path(PATH_PREFIX) + "/" + player.id + queryParams()); return "GET".equals(request.getMethod()) ? proxyWithUri.get() : proxyWithUri.post(); } // can be combined with more specific, regular request mapping methods … } Our URI prefix, which should be stripped Proxy all GETs & POSTs without specific mapping Copy non-sensitive headers Base URL + stripped path + custom path segment + query params Perform actual proxy call
  • 30. Replacing Hystrix  Circuit breaking: use Resilience4J instead  Didn’t like bulk heading as solution to prevent running out of request handling threads  Solution: use additional Tomcat connector on separate port with custom thread pool  Point Kubernetes liveness/readiness endpoints to that
  • 31. Custom Tomcat Connector @Configuration @EnableConfigurationProperties(HealthConnectorProperties.class) public class TomcatAutoConfiguration { @Bean WebServerFactoryCustomizer<TomcatServletWebServerFactory> tcHealthConnectorCustomizer(HealthConnectorProperties connector) { return server -> { Connector healthConnector = new Connector(); healthConnector.setPort(connector.getPort()); AbstractProtocol protocol = (AbstractProtocol) healthConnector.getProtocolHandler(); protocol.setMinSpareThreads(connector.getMinThreads()); protocol.setMaxThreads(connector.getMaxThreads()); server.addAdditionalTomcatConnectors(healthConnector); }; } } probes: liveness: enabled: false path: /actuator/health/liveness port: 8888 readiness: enabled: false path: /actuator/health/readiness port: 8888
  • 32. Conclusion  Use what the frameworks provide you with  Don’t be afraid to extend them  Build your own tools to support your system  Know what’s out there, know what’s supported  Follow me to Q&A for questions & discussions!