protected function reportDatabaseConnectionException(DatabaseConnectionException $exception)
    {
        /**
         * If the shop is not in debug mode, a "shop offline" warning is send to the shop admin.
         * In order not to spam the shop admin, the warning will be sent in a certain interval of time.
         */
        if ($this->messageWasSentWithinThreshold() || $this->_isDebugMode()) {
            return;
        }

        $result = $this->sendOfflineWarning($exception);
        if ($result) {
            file_put_contents($this->offlineWarningTimestampFile, time());
        }
    }