Demystifying stateful apps on Kubernetes by deploying an etcd cluster

Click for: original source

Not all apps are the same - when we deploy them to our Kubernetes cluster, we have to take that into account. One classification of apps is between stateful & stateless. By Dimitris Kapanidis.

A stateless app is an application program that does not save client data generated in one session for use in the next session with that client. As an example a REST API backend service that performs requests on a database is stateless, though the database itself is stateful. One of the main benefit of stateless apps is that their instances can be scaled on multiple replicas without issues

The article then pays attention to:

  • Stateless apps
  • Start with Stateless
  • Stateful apps
  • Deploying an etcd cluster
  • Testing High Availability

There are different patterns to accomplish high availability (HA) for stateful apps, autthor will use as example how etcd distributed key-value store works. Making a stateful app to work in Kubernetes is not difficult, but making it work so that it is resilient and in high-availability mode depends on the architecture of the app itself, etcd is a battle-tested example in Kubernetes, but other solutions such as relational databases are a bit more complicated. You will also get all the configuration files and commands for running the kubernetes. Easy!

[Read More]

Tags kubernetes containers docker devops