DevConf.CZ

Building Leader Election with Zookeeper, Go and Docker
06-15, 10:15–11:35 (Europe/Prague), A218 | Workshops (capacity 20)

Abstract

In this workshop, we'll build a distributed application that interacts with Apache Zookeeper to elect one leader among all its nodes. Our application will guarantee the presence of at most one leader at all times, even if some of the nodes are down. We'll use Go to write the application, and we'll run it as a cluster using Docker.

Objectives

  • Understanding the what(s) and why(s) of leader-election.
  • Overview of Zookeeper and its Sequential Ephemeral Z-Nodes.
  • Deploying a Zookeeper cluster locally.
  • Hands-on implementation of leader-election using Zookeeper in Go.
  • Testing the application.

Requirements

  • Participants should already have Docker and Go installed.
  • It is recommended to keep the zookeeper:3.9 container image downloaded to save time and internet problems.
See also:

I am a distributed systems enthusiast with about 4.5 years of experience, currently working at Red Hat as a Senior Software Engineer. My first job, at KNNX Corp, focused on building Blockchain-based applications, which initially sparked my interest in the domain of distributed systems.

At KNNX Corp, I spent most of my time learning about consensus algorithms, the CAP theorem, Byzantine fault tolerance and more. My improved knowledge in this domain helped me climb the ranks quicker and I ended up leading a development team within just 1 year of joining.

At Red Hat, I work in the Subscriptions team. The product I'm currently working on attempts to bring together the big three cloud providers under one seamless platform. It demands extensive high-level design skills, which I honed during my previous role.

Apart from my professional life, I like to work on personal projects, just for fulfillment. I also like to cook, workout and write fiction.