Skip navigation
Rahila Syed

Rahila Syed

Senior Software Engineer @ Microsoft

I have 12 years of experience working as a PostgreSQL developer. I have co-authored patches for WAL compression, default partitioning, vacuum progress checker, column filtering in logical replication and miscellaneous others. I have worked on an extension that provides a distributed database based on PostgreSQL. Currently, I am working with Microsoft on designing and developing features for open-source PostgreSQL.

POSETTE 2025 Talk

Designing a monitoring feature in PostgreSQL

(Livestream 1)

This talk will provide a detailed explanation of designing, implementing, and evaluating a new monitoring feature that delivers dynamic, on-demand statistics in core PostgreSQL. I will describe the monitoring subsystem in PostgreSQL, focusing on the different types of statistics systems such as cumulative and dynamic.

I will then demonstrate how to design and implement a monitoring feature for reporting memory context statistics. This includes discussing how and when to collect statistics, updating shared memory, and defining SQL views for the collected data. I will explore the use of dynamic shared memory for managing non-fixed-amount statistics, with a comparison between DSAs and DSMs. I will illustrate methods for minimizing the overhead associated with collecting such statistics, highlighting trade-offs such as response time of the monitoring query versus its memory consumption. Finally, I will describe the iterative journey of designing this system, examining various design iterations and the pros and cons of each approach. I will describe how to encapsulate certain functionalities, such as sending a request to copy statistics to a process, waiting for new statistics into interfaces. This approach aims to simplify adding similar on-demand statistics in the future.

talk bubbles
Join the conversation

Use the hashtag #PosetteConf