Episode

Auto scaling Azure Cosmos DB for PostgreSQL with Citus, Grafana & Azure Serverless | Citus Con 2023

with Lucas Borges Fernandes

Video of a conference talk and demo about auto scaling Azure Cosmos DB for PostgreSQL with Citus, Grafana, & Azure Serverless, delivered by Lucas Borges at Citus Con: An Event for Postgres 2023. Azure Cosmos DB for PostgreSQL is a managed service offering that is powered by the open-source Citus database extension to Postgres. One of the top Citus features is the ability to run PostgreSQL at any scale, on a single node as well as a distributed database cluster.

This talk includes a demo to show what you can do as your application needs to scale: You can add more nodes to the Azure Cosmos DB for PostgreSQL cluster, rebalance existing data across the new Postgres nodes, and seamlessly scale out. However, these operations require manual intervention: a) first you must create alerts on metrics, b) then, based on those alerts, you need to add more nodes, c) then you must kick off and monitor the shard rebalancer. Automating these steps will give you a complete auto scale experience—and make your life so much easier. The demo shows you how to “auto scale” by using existing tools such as Grafana & Azure Serverless (aka Azure Functions.), configuring Grafana to capture metrics from Azure Cosmos DB for PostgreSQL, configure alerts based on those metrics, trigger Azure Serverless function using Grafana alerts to automate the process of scaling out, both automatic node addition and shard rebalancer maintenance, as icing on the cake, we will also demonstrate automatic tenant isolation!

Lucas Borges Fernandes is a Brazilian software engineer with years of experience in the field of application development. He also has a MSc in the field of distributed systems. He's currently working at Microsoft as a Customer Engineer for the Azure Cosmos DB for PostgreSQL team.

Connect

  • Citus Con An Event for Postgres | Twitter: @CitusCon

Azure Cosmos DB