Reading time: 9 minutes
PostgreSQL is the World’s most advanced Open Source Relational Database. The interview series “PostgreSQL Person of the Week” presents the people who make the project what it is today. Read all interviews here.
Please tell us about yourself, and where you are from.
Hi, I’m Dmitry, proud inhabitant of the Earth (do not trust those rumors stating otherwise), PostgreSQL contributor, trying to make the world a bit better place.
How do you spend your free time? What are your hobbies?
The way I spend my free time one day will bring me the title “Most Boring Person of the Year”. I like to read good books and play strategy board games. If at a PostgreSQL conference you notice a strange person hanging around with a chessboard, chances are high that it’s me.
Any Social Media channels of yours we should be aware of?
I have my blog where I post interesting ideas and results of my research with a questionable frequency. There is also a twitter account @erthalion, but these days I’m experimenting with reducing consumption of social media of this sort. You would be surprised how much of a different perspective you can get simply by replacing reading the Twitter feed with rss of carefully selected blogs.
Last book you read? Or a book you want to recommend to readers?
There are too many books I would like to recommend, probably I have to write a blog post instead. The last book I’ve read is “QualityLand 2.0”, an anti-utopian satire on our technological society. And now I’m battling my way through “Introduction to category theory” from H. Simmons, full of math which is definitely over my head, but brings a lot of joy when you can get a glimpse of understanding.
Any favorite movie, or show?
It’s always hard to answer “your favorite …” questions, there are so many good things that are simply different and there is no obvious winner. But one thing that comes into my mind at this moment is how much I’ve enjoyed the tv show “Dirk Gently’s Holistic Detective Agency”.
What is the best advice you ever got?
Probably the best one was coming from my soul mate about taking breaks, often and of a high quality. This simple but powerful advice, sometimes disguised under different forms, could be applied almost everywhere. Even R. Hamming in his “The art of doing science and engineering” has mentioned that “monomaniacal pursuit often doesn’t work; the temporary dropping of the idea sometimes seems to be essential to let the subconscious find a new approach”.
When and how did you start with PostgreSQL?
My first real encounter with PostgreSQL was quite different from what you can normally hear I guess, because it wasn’t about using it for something, but rather an encounter with the community. In 2014 I was watching a conference talk by Oleg Bartunov about a freshly implemented feature called “jsonb”. He had mentioned the GSoC PostgreSQL project, which sounded pretty exciting to me, and even gave me a few pointers about what could be helpful in its context. I’ve successfully failed my application, but eventually my efforts implementing jsonb modification functionality had landed in PostgreSQL 9.5, thanks to Andew Dunstan help. This whole turn of events was somewhat unexpected, but since then I’ve started dividing my time between writing postgraduate work in Computational Fluid Dynamics and PostgreSQL. Probably the funniest part of this story is that at this time I was working on exclusively MongoDB based projects.
What other databases are you using? Which one is your favorite?
My practical experience is almost exclusively focused on PostgreSQL, but I like to explore new horizons. For example I’m quite impressed by ScyllaDB and their efforts on performance, interested in SageDB because of the vision of the ML future in databases, surprised by Project-M36 for its opinionated nature and amused by QuineDB, which is a quine that is also a key/value store.
On which PostgreSQL-related projects are you currently working?
At the moment I’m busy with a couple of patches to PostgreSQL. One is about implementing index skip scan, which would allow performing index scans without a leading prefix much faster. Another one is about solving the old pain point of pg_stat_statements, namely when it stores essentially the same queries, which have an array of parameters, as different queries depending on the array size. Many other ideas are swarming in my head, but I do not always have time to work them out. A few examples when I could actually find a moment are postgres-bcc, a set of
bcc (and in some cases even directly
libbbpf) based monitoring scripts for PostgreSQl, or an extension pg_simdjson, which uses
simdjson to parse data into jsonb faster. And the vacuum happened after generic type subscripting was committed I’m trying to fill in with patch review.
As you can see I’m trying to address the task of contributing to PostgreSQL from different perspectives. On one hand it is of course writing patches, e.g. for jsonb, or small improvements around pluggable storage,
io_uring experiments, bug fixing. On the other hand it’s always interesting to see how PostgreSQL is interacting with other systems, how it could be monitored, profiled etc.
What is the most annoying PostgreSQL thing you can think of? And any chance to fix it?
I could be biased in this, but the most annoying thing for me is to explain to folks, who never used PostgreSQL, why certain approaches are no-go and considered to be a “bad practise”. Fortunately the documentation is getting better, and tools for semi-automated checking of best practices are getting more popular.
What is the feature you like most in the latest PostgreSQL version?
I’m excited about the support of different compression methods. Somehow at one point I lost hope it would get there, glad to see it was successfully finished.
Adding to that, what feature/mechanism would you like to see in PostgreSQL? And why?
Here my vote goes into two different directions. First, making PostgreSQL more I/O asynchronous via supporting stuff like
io_uring would be definitely a game changer. Second, having a couple more storage engines to support different types of workloads would most certainly be a life-saver in many situations. If you think about this from a higher level, the former one could make PostgreSQL “deeper” in the technical sense, while the latter one makes it “broader” by opening more areas where it could be applied, sort of orthogonal directions.
Could you describe your PostgreSQL development toolbox?
No surprises here, vim to write, gcc to compile, gdb/perf/valgrind to troubleshoot and neomutt to tell about the results. I’m also using a few funny scripts for gdb, one is gdb-dashboard, another is a customized version of gdbpg from Tomas Vondra, but that’s it.
As a side note, PostgreSQL itself could be considered a nice development tool, so much introspection and well-written commentaries are hidden within it.
Which skills are a must have for a PostgreSQL developer/user?
Sometimes I think it’s patience, but of course it’s an ability to dig out of the depth of the history any clues or reasons why something was done in a certain way, and when the time has come to change it.
Do you use any git best practices, which makes working with PostgreSQL easier?
It’s not about git itself, but I find some Linux Kernel git workflows are working nice with PostgreSQL. No need for a cover letter, but maximum independent commits, format patch and tags like “Reviewed-by”, “Tested-by” are rather practical. It could be also interesting to think about scripts like
get_maintainer.pl to suggest who can share some experience relevant for the code change, or
checkpatch.pl for ensuring some style details, although it’s already somewhat far-fetched.
Which PostgreSQL conferences do you visit? Do you submit talks?
Yes, I enjoy giving talks at various conferences, not necessarily PostgreSQL exclusive ones. No particular preferences about which conference to visit or where to submit a talk, but it’s always interesting to meet members of the community you’ve never seen before. I’m also trying to keep my talks accessible, and after a couple of conferences when the talk is already refined enough, I usually convert its content into a blog post.
Do you think PostgreSQL has a high entry barrier?
I don’t think so, although even if a project has a relatively high entry level it doesn’t immediately mean it’s bad. As long as it can sustain itself, every level is fine.
What is your advice for people who want to start PostgreSQL developing - as in, contributing to the project. Where and how should they start?
Probably the most direct way is to go to the commitfest application, pick up some interesting patches and start reading their code and the corresponding discussion. Even if you have no clue at the beginning, after some time of reading the relevant bits of PostgreSQL code you’ll definitely become enlightened thanks to the codebase quality.
Do you think PostgreSQL will be here for many years in the future?
If we talk about PostgreSQL as a technical project, I believe yes, in one or another form at least. But I’m deeply convinced that there is more to it. In my perception PostgreSQL is equal to the idea of an excellent independent general purpose open source database, and it’s of an extreme importance for the society. One can just take it and use it to improve the world without becoming dependent on any large company. And this idea, I hope, is immortal indeed.
Would you recommend PostgreSQL for business, or for side projects?
Not only would I recommend, sometimes I would even insist on that. It’s obviously highly opinionated, but I think the amount of flexibility PostgreSQL gives you with various extensions, supported workloads and configuration modes is unbeatable.
Are you reading the -hackers mailing list? Any other list?
Which other Open Source projects are you involved or interested in?
I’m trying to spend a fair share of time making myself familiar with various Linux Kernel subsystems, it definitely makes my knowledge “around PostgreSQL” better. Sometimes I submit patches there as well and sometimes, when the moon is full and the stars are in the right position, those patches even getting accepted.
My other passion is the Glasgow Haskell Compiler, another well engineered system which provides a lot of “aha” moments.