Reactive microservices with play and akka

  • View
    1.238

  • Download
    1

  • Category

    Software

Preview:

Citation preview

Reactive Microservices Making Microservices Reactive using Play & Akka

Scala Matsuri

Christopher Hunt @huntchr

5 Minute Microservices 2

Reactive Microservices

http://www.reactivemanifesto.org/It’s for Developers AND Operations

• Resiliency• The system stays responsive in the face of failure

• Elasticity• The system stays responsive under varying

workload

5 Minute Microservices 3

Example Problem

• Customer Microservice• Create• Retrieve

• Persisting to Datastore• Local Caching

Let’s Do This!

It’s a Microservice!

5 Minute Microservices 6

But is it Reactive?

• Resilient• What happens if/when our Datastore fails?

• Elastic• How do we scale out?

• Cache Management• How to maintain the cache across multiple nodes?

5 Minute Microservices 7

Solution• Cluster our Datastore

• Postgres BDR• https://github.com/huntc/postgres-bdr

• Run on multiple nodes• Deploy to ConductR• https://conductr.typesafe.com/

• Signal for cache updates• Akka Data Replication• https://github.com/patriknw/akka-data-replication

5 Minute Microservices 8

What is ConductR?ConductR is a solution for deploying and managing reactive applications across a cluster of machines.

Make This Reactive!

5 Minute Microservices 10

Reactive Solution Checklist

✓ Resilient✓ Postgres node failure

✓ Elastic✓ Scale out Customer and Postgres✓ Blue/Green Rolling Upgrade

✓ Cache Management✓ Replicate across nodes

Questions?

Thank you!

Christopher Hunt @huntchr

Recommended