public function process_logstore_database_log($data) {
        // Do not bother processing if we can not add it to a database.
        if (!self::$extdb || !self::$extdbtablename) {
            return;
        }

        $data = $this->process_log($data, get_config('logstore_database', 'jsonformat'));

        if ($data) {
            self::$extdb->insert_record(self::$extdbtablename, $data);
        }
    }