Alice au pays des micro-services

By Julien Giovaresco and Willy Malvault

bridge logo
BRIDGE platform

Some figures

  • 250+ clients
  • 515k+ shops
  • 5M monthly unique visitors
  • 15M daily visited pages

Legacy

  • July 2009
  • 1 GIT repository
  • 8 developers
  • 25,814 commits
  • 1,047 releases
why going micro service ?

Ready to trip down the rabbit hole ?

Alice tripping down the hole

1

Architecture & Design

bridge overview
bridge overview
bridge overview

Leitmotiv

« Go as micro as possible! »
alice late gif
simple / modular / easy / tests / refacto
bridge overview
bridge overview
bridge overview
bridge overview
bridge overview

Want to Share some Library ?

(Authentication, DB, Access control, ...)
whoah no
Try to avoid! But if you do, do micro libraries and keep all your services up to date!

Promising evolutions

  • Setup an API gateway
  • Use a storage API

alice promising world gif

2

Assembling blocks

Microservices caveats

  • Configuration on multiple spots
  • Deployment agility

Kubernetes

orchestrator
  • Containers orchestrator
  • Started by Google
  • Run and manage containers
  • Provides container grouping, load balancing, auto-healing, scaling features

Our backbone

alice worship
  • Internal DNS
  • Centralized configuration
  • The Kubernetes way of managing outages
  • Easy-peasy deploy

How to deploy ?

  • Produce a big YAML
  • Give it to Kubernetes
eating alice

How to produce this yaml ?

  • Meta-project ensure consistency
  • Jenkins pipelines
alice cards gif

Release

  • Weekly
  • More Jenkins pipelines
  • Our process
    • Update version in meta-project
    • Tests
    • Tag

3

Share data between services

Your services needs to share data

sharing tea gif
data-synchro

The different path

alice choose path
  1. One single shared DB (strong coupling)
  2. Ask data when needed (slow read)
  3. Full data copy (NoSQL way : fast read)
data-copy-crud
data-copy-request
product-copy-synchro
data synchro hell
data synchro hell
data synchro hell
data synchro hell
data synchro hell
data synchro hell
data synchro hell
Data Synchro complexity grows along with service decentralization
gone mad

Further solutions

4

Few more advices

The caching misery

alice hiding
  • Inside K8S cluster
  • Outside K8S cluster
  • ?

You need development stacks

alice friends
  • Dedicate cluster
  • External services
  • Internal services

The big messaging bugs (meta-data mandatory)

alice maze
  • Monitoring
  • User
  • Correlation id
  • ...

Use explicit contract

alice hiding
  • Avro, Protobuf, ...
  • GraphQL

The slide to remember

  • We did it! So can you!
  • We don't regret it (for now)
  • Go as micro as you can
  • Use an orchestrator
  • Data distribution is more complex than you think!

Thank you!