Tech News
← Back to articles

SQL performance improvements: finding the right queries to fix

read original related products more articles

A few weeks ago, we massively improved the performance of the dashboard & website by optimizing some of our SQL queries. In this post, we'll share how we identified the queries that needed work. In the next post, we'll explore how we fixed each of them.

We'll cover the basics and gradually work our way up to the more advanced/complex ways of identifying slow queries.

In this post, you'll see:

Let's go!

What these results look like #

As a reminder, this is the resulting performance gain for the dashboard & some of our internal APIs:

These graphs come from the Oh Dear uptime & performance monitoring we perform.

Now let's get started identifying which queries need optimising.

Enable the debug-bar in your local environment #

The easiest place to start investigating queries is locally, in your development environment. Most frameworks have the concept of a "debug bar" - in the case of Laravel applications, the most widely used is the barryvdh/laravel-debugbar package that offers excellent insights.

... continue reading