Slow SQL Logging
Note: This feature is currently in Beta. You need to install the beta PHP extension and daemon that support this beta feature and be marked as Beta customer to use it.
The Slow SQL Log feature in Tideways is similar to MySQL’s own slow query log, but extended by application context information such as Stacktrace and which URL / transaction the query occurred on. In addition it also groups the same slow SQL statement into a group similar how Error/Exception tracking works, so that you can see how often the slow query occurs.
SQL slow log is enabled on all plans and licenses, but the bigger your license the lower you can set the possible query duration threshold. See the pricing page for details.
To configure slow SQL logging to your need, reduce the INI setting from its default of 10 seconds to a lower value:
This example means every query slower than 250ms is considered slow query and appears in the log.
Note: Right now slow SQL queries are not triggering notifications configured for the "New Error/Exception" notification type.