Baron is a performance and scalability expert who participates in various database, open-source, and distributed systems communities. He has helped build and scale many large, high-traffic services for Fortune 1000 clients. He has written several books, including O’Reilly’s best-selling High Performance MySQL. Baron has a CS degree from the University of Virginia.



author:

Database

The Left-Prefix Index Rule

February 5, 2019

There’s an important heuristic in database indexing that I call the left-prefix rule. It helps you understand whether the database will be able to make the best use of a multi-column index to speed up a query. It’s one of a small handful of …


author:

Database

Covering Indexes in MySQL, PostgreSQL, and MongoDB

February 1, 2019

A covering index is a fantastic query performance optimization. An index covers a query when the index has all the data needed to execute the query, so the server can retrieve the query’s data without reading any rows or documents. Covered queries are usually …



author:

Database

What Is Concurrency in a Database?

January 28, 2019

Databases are confusing! Not only are they complicated bits of software, but database jargon is really complicated. Part of this comes from the number of words with multiple meanings: depending on which community you spend time in, there are multiple meanings for words like …


author:

Database

Your ORM and SELECT FOR UPDATE

January 23, 2019

If you use a programming language framework such as Django or Ruby on Rails, chances are you use an ORM to help you construct queries. What’s an ORM? If you’re not familiar with ORMs, an ORM is an Object-Relational Mapper, which helps you map …


author:

Database

The Difference Between Lock Wait Timeout and Deadlock

September 12, 2018

If you use ACID transactional databases, you’ve probably heard of lock wait timeouts and deadlocks. What are these? And how are they different? Inevitably, many of us will come across these phenomena at some point. Most databases use locking strategies to make sure data …


author:

Database

What Is Cardinality in Monitoring?

July 30, 2018

I wrote a couple of “definitions and nuances” posts about terminology in databases recently (cardinality, selectivity), and today I want to write one about cardinality in monitoring, as opposed to cardinality in databases. If you’ve seen discussions of “high-cardinality dimensions” or “observability requires support …


author:

Database

What is Database Index Selectivity?

July 18, 2018

I wrote recently about database cardinality, and there’s a closely related topic that is equally confusing and I want to explain too: index selectivity. Index selectivity is how tightly a database index helps narrow the search for specific values in a table. To illustrate …