Evolution of Integration and
Microservices with Service Mesh
and Ballerina
@christianposta
Christian Posta
Chief Architect, cloud application development
Twitter: @christianposta
Blog: http://blog.christianposta.com
Email: christian@redhat.com
Slides: http://slideshare.net/ceposta
• Author “Microservices for Java developers”
and “Introducing Istio Service Mesh”
• Committer/contributor lots of open-source projects
• Blogger, speaker, mentor, leader
https://www.manning.com/books/istio-in-action
Existing investment
New capabilities need to work with
existing investment
As we move to services architectures,
we push the complexity to the space
between our services.
@christianposta
@christianposta
• Orchestrate calls across multiple microservices
• Calls in parallel, sequential, etc
• Aggregate, combine, transform, split, on “messages”
• Deal with errors, unexpected results
Application integration
@christianposta
• Deal with atomicity / consistency issues
• Message idempotency / message de-dupe
• APIs / DDD anti-corruption layers / adapters
• Tie in with existing “backend systems”
• Deal with making calls over the network
Application integration
@christianposta
• Service discovery
• Load balancing
• Timeouts
• Retries
• Circuit breaking
• Rate limiting
Application networking
@christianposta
@christianposta
Application safety and correctness in a
distributed system is the responsibility of
the application teams.
@christianposta
Integration is part of the
application-development process.
Meet Ballerina
http://ballerina.io
• A new language purpose-built for creating services/APIs and
integrating with existing investments/services
• Built by WSO2
• Static, strong typing with language constructs that make
services and service interaction first-class citizens
• Strong focus on network awareness
Ballerina is…
@christianposta
• Built around a “sequence-diagram” mental model
• Round-trip development as a first-class citizen
• Native concurrency model
• Solves problems around application integration like:
Ballerina is…
@christianposta
• Service call orchestration
• Aggregating responses
• Data security
• Transactions, compensations
• Quickly build APIs based on OAPI
• Reusable protocol / backend adapters
• Long-running execution with checkpointing
• Stream based processing
@christianposta
So: what about application networking?
• Service discovery
• Retries
• Timeouts
• Load balancing
• Rate limiting
• Thread bulk
heading
• Circuit breaking
@christianposta
Application networking
• Edge/DMZ routing
• Surgical, per-request
routing
• A/B rollout
• Traffic shaping
• Internal releases / dark
launches
• Request shadowing
• Fault injection
• adaptive, zone-aware
• Deadlines
• Health checking
• Stats, metric, collection
• Logging
• Distributed tracing
• Security
• Netflix Hystrix (circuit breaking / bulk heading)
• Netflix Zuul (edge router)
• Netflix Ribbon (client-side service discovery / load balance)
• Netflix Eureka (service discovery registry)
• Brave / Zipkin (tracing)
• Netflix spectator / atlas (metrics)
“Microservices” patterns
@christianposta
http://bit.ly/application-networking@christianposta
Screw Java - I’m using NodeJS!
JavaScript is for rookies, I use Go!
But python is so pretty!
I prefer unreadability… Perl for me!
@christianposta
In practice, operability of our services
becomes a top priority very fast
@christianposta
Let’s optimize for operability
@christianposta
Meet Envoy Proxy
http://envoyproxy.io
As a service-instance proxy
@christianposta
A service mesh is a distributed application infrastructure
that is responsible for handling network traffic on behalf
of the application in a transparent, out of process manner.
A service mesh helps to solve problems related to
resiliency, security, observability, and routing control.
@christianposta
Time for definitions:
Service mesh technologies typically provide:
• Service discovery / Load balancing
• Secure service-to-service communication
• Traffic control / shaping / shifting
• Policy / Intention based access control
• Traffic metric collection
• Service resilience
@christianposta
Open-source, service-mesh implementations
• Istio.io
http://istio.io
• Consul Connect
http://consul.io
• LinkerD
http://linkerd.io
@christianposta
@christianposta
Isn’t there overlap??
• Service discovery
• Load balancing
• Timeouts
• Retries
• Circuit breaking
• Rate limiting
• Distributed tracing
• … some others …
Leverage the service mesh for key, consistent application-
networking behavior.
Develop a workflow for application teams that includes
configuration of the service mesh as part of the application.
Opt for language-specific implementations when the general
service mesh solution doesn’t adequately solve a specific
problem.
@christianposta
Key takeaways:
Resist the urge to put application-integration logic into the
service mesh.
Understand the “why” of service mesh and seek to keep the
boundary delineated
@christianposta
Key takeaways:
Demo!
http://bit.ly/istio-tutorial
Thanks!
BTW: Hand drawn diagrams made with Paper by FiftyThree.com 
Twitter: @christianposta
Blog: http://blog.christianposta.com
Email: christian@redhat.com
Slides: http://slideshare.net/cepostaFollow up links:
• http://ballerina.io
• http://istio.io
• http://envoyproxy.io
• http://developers.redhat.com/blog
• http://blog.christianposta.com/istio-workshop/slides/
• http://blog.openshift.com
• https://www.redhat.com/en/open-innovation-labs

KubeCon NA 2018: Evolution of Integration and Microservices with Service Mesh and Ballerina

  • 1.
    Evolution of Integrationand Microservices with Service Mesh and Ballerina @christianposta
  • 2.
    Christian Posta Chief Architect,cloud application development Twitter: @christianposta Blog: http://blog.christianposta.com Email: christian@redhat.com Slides: http://slideshare.net/ceposta • Author “Microservices for Java developers” and “Introducing Istio Service Mesh” • Committer/contributor lots of open-source projects • Blogger, speaker, mentor, leader
  • 3.
  • 5.
  • 6.
    New capabilities needto work with existing investment
  • 7.
    As we moveto services architectures, we push the complexity to the space between our services. @christianposta
  • 8.
  • 9.
    • Orchestrate callsacross multiple microservices • Calls in parallel, sequential, etc • Aggregate, combine, transform, split, on “messages” • Deal with errors, unexpected results Application integration @christianposta
  • 10.
    • Deal withatomicity / consistency issues • Message idempotency / message de-dupe • APIs / DDD anti-corruption layers / adapters • Tie in with existing “backend systems” • Deal with making calls over the network Application integration @christianposta
  • 11.
    • Service discovery •Load balancing • Timeouts • Retries • Circuit breaking • Rate limiting Application networking @christianposta
  • 12.
    @christianposta Application safety andcorrectness in a distributed system is the responsibility of the application teams.
  • 14.
    @christianposta Integration is partof the application-development process.
  • 15.
  • 16.
    • A newlanguage purpose-built for creating services/APIs and integrating with existing investments/services • Built by WSO2 • Static, strong typing with language constructs that make services and service interaction first-class citizens • Strong focus on network awareness Ballerina is… @christianposta
  • 17.
    • Built arounda “sequence-diagram” mental model • Round-trip development as a first-class citizen • Native concurrency model • Solves problems around application integration like: Ballerina is… @christianposta • Service call orchestration • Aggregating responses • Data security • Transactions, compensations • Quickly build APIs based on OAPI • Reusable protocol / backend adapters • Long-running execution with checkpointing • Stream based processing
  • 21.
    @christianposta So: what aboutapplication networking?
  • 22.
    • Service discovery •Retries • Timeouts • Load balancing • Rate limiting • Thread bulk heading • Circuit breaking @christianposta Application networking • Edge/DMZ routing • Surgical, per-request routing • A/B rollout • Traffic shaping • Internal releases / dark launches • Request shadowing • Fault injection • adaptive, zone-aware • Deadlines • Health checking • Stats, metric, collection • Logging • Distributed tracing • Security
  • 23.
    • Netflix Hystrix(circuit breaking / bulk heading) • Netflix Zuul (edge router) • Netflix Ribbon (client-side service discovery / load balance) • Netflix Eureka (service discovery registry) • Brave / Zipkin (tracing) • Netflix spectator / atlas (metrics) “Microservices” patterns @christianposta
  • 25.
  • 26.
    Screw Java -I’m using NodeJS! JavaScript is for rookies, I use Go! But python is so pretty! I prefer unreadability… Perl for me! @christianposta
  • 27.
    In practice, operabilityof our services becomes a top priority very fast @christianposta
  • 28.
    Let’s optimize foroperability @christianposta
  • 30.
  • 32.
    As a service-instanceproxy @christianposta
  • 33.
    A service meshis a distributed application infrastructure that is responsible for handling network traffic on behalf of the application in a transparent, out of process manner. A service mesh helps to solve problems related to resiliency, security, observability, and routing control. @christianposta Time for definitions:
  • 34.
    Service mesh technologiestypically provide: • Service discovery / Load balancing • Secure service-to-service communication • Traffic control / shaping / shifting • Policy / Intention based access control • Traffic metric collection • Service resilience @christianposta
  • 35.
    Open-source, service-mesh implementations •Istio.io http://istio.io • Consul Connect http://consul.io • LinkerD http://linkerd.io @christianposta
  • 38.
    @christianposta Isn’t there overlap?? •Service discovery • Load balancing • Timeouts • Retries • Circuit breaking • Rate limiting • Distributed tracing • … some others …
  • 39.
    Leverage the servicemesh for key, consistent application- networking behavior. Develop a workflow for application teams that includes configuration of the service mesh as part of the application. Opt for language-specific implementations when the general service mesh solution doesn’t adequately solve a specific problem. @christianposta Key takeaways:
  • 40.
    Resist the urgeto put application-integration logic into the service mesh. Understand the “why” of service mesh and seek to keep the boundary delineated @christianposta Key takeaways:
  • 41.
  • 42.
    Thanks! BTW: Hand drawndiagrams made with Paper by FiftyThree.com  Twitter: @christianposta Blog: http://blog.christianposta.com Email: christian@redhat.com Slides: http://slideshare.net/cepostaFollow up links: • http://ballerina.io • http://istio.io • http://envoyproxy.io • http://developers.redhat.com/blog • http://blog.christianposta.com/istio-workshop/slides/ • http://blog.openshift.com • https://www.redhat.com/en/open-innovation-labs

Editor's Notes

  • #2 How many first KubeCon? Lots of good technology coming out Kubernetes has enabled lots of new cloud-native solutions to be layered on top and around In this talk we’ll look at some of this new technology, and more importantly where they fit in our architecture and how to think about using them. There are no silver bullets.
  • #4 How many people are embarking on projects to drive innovation in their organizations? How many people think those projects will succeed? How many people can predict the future? How many people believe their organization’s executives can predict the future?
  • #5 How many people are embarking on projects to drive innovation in their organizations? How many people think those projects will succeed? How many people can predict the future? How many people believe their organization’s executives can predict the future?
  • #6 How many people are embarking on projects to drive innovation in their organizations? How many people think those projects will succeed? How many people can predict the future? How many people believe their organization’s executives can predict the future?
  • #7 How many people are embarking on projects to drive innovation in their organizations? How many people think those projects will succeed? How many people can predict the future? How many people believe their organization’s executives can predict the future?
  • #9 As we start to make calls out across multiple services, we have to deal with the network .
  • #10 Apache Camel can enable legacy backends to participate in a REST-based set of services by quickly exposing a REST service interface using its expressive DSL.. The DSL plugins right into the rest of the Apache Camel DSL allowing you to quickly expose a REST endpoint that can describe an API as well as integrate with backend services by mediating, routing, transforming and otherwise changing the shape of data or even content of a payload with enricher, resequence, and recipient list patterns.
  • #11 Apache Camel can enable legacy backends to participate in a REST-based set of services by quickly exposing a REST service interface using its expressive DSL.. The DSL plugins right into the rest of the Apache Camel DSL allowing you to quickly expose a REST endpoint that can describe an API as well as integrate with backend services by mediating, routing, transforming and otherwise changing the shape of data or even content of a payload with enricher, resequence, and recipient list patterns.
  • #12 In the past we tried to hide the network with EJBs, DCOM, client server/CORBA abstractions Network calls should NOT be treated like local calls
  • #13 …… new challenge….. Let’s come back to that…..
  • #15 There are ways to do this..
  • #16 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.
  • #19 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.
  • #20 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.
  • #21 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.
  • #22 …… new challenge….. Let’s come back to that…..
  • #23 At one point we called these “microservices patterns”
  • #27 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.
  • #30 One large database! We should focus on how we design our data models so that they can be sharded and distributed…. Focus on transactions, etc not 2PC
  • #31 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.
  • #32 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.
  • #33 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.
  • #34  A service mesh is a distributed application infrastructure that is responsible for handling network traffic on behalf of the application in a transparent, out of process manner.
  • #35 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.
  • #36 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.
  • #39  A service mesh is a distributed application infrastructure that is responsible for handling network traffic on behalf of the application in a transparent, out of process manner.
  • #40  A service mesh is a distributed application infrastructure that is responsible for handling network traffic on behalf of the application in a transparent, out of process manner.
  • #41  A service mesh is a distributed application infrastructure that is responsible for handling network traffic on behalf of the application in a transparent, out of process manner.
  • #42 Get back to first principles. Focus on principles, patterns, methodologies. Tools will help, but you cannot start with tools.