Problem/Motivation
Getting multiple failed backups for sites that are large enough the backup does not complete before the queue is processed again.
_hosting_backup_queue_get_backup function in hosting_backup_queue.module calls hosting_get_most_recent_task to determine status of most recent backup.
hosting_get_most_recent_task returns FALSE as the db_query fails due to incorrect SQL.
The db_query named placeholder uses ! rather than : turning on SQL command logging yields:
SELECT t.nid FROM hosting_task t INNER JOIN node n ON n.vid = t.vid WHERE task_type = !task_type and t.rid = !t.rid ORDER BY t.vid DESC limit 1
i.e. the placeholder doesn't get swapped out.
Also t.rid fails as a named placeholder.
Proposed resolution
Switch the named placeholders to :task_type and :t_rid
Patch attached.
| Comment | File | Size | Author |
|---|---|---|---|
| hosting_task.module.patch | 794 bytes | northstowe |
Comments
Comment #2
colanSeems strange nobody ran into this earlier.
Comment #4
helmo commentedcommitted.