Minor queue fixes, probably not very important. Preparing for cron
This commit is contained in:
parent
0a93fa68f3
commit
1a0e17fea6
@ -44,7 +44,7 @@ class DBQueueManager extends QueueManager
|
||||
$qi->created = common_sql_now();
|
||||
$result = $qi->insert();
|
||||
|
||||
if (!$result) {
|
||||
if ($result === false) {
|
||||
common_log_db_error($qi, 'INSERT', __FILE__);
|
||||
throw new ServerException('DB error inserting queue item');
|
||||
}
|
||||
|
@ -67,6 +67,9 @@ abstract class QueueManager extends IoManager
|
||||
self::$qm = new UnQueueManager();
|
||||
} else {
|
||||
switch ($type) {
|
||||
case 'cron':
|
||||
self::$qm = new GNUsocialCron();
|
||||
break;
|
||||
case 'db':
|
||||
self::$qm = new DBQueueManager();
|
||||
break;
|
||||
|
@ -37,7 +37,7 @@ require_once INSTALLDIR.'/scripts/commandline.inc';
|
||||
|
||||
$daemons = array();
|
||||
|
||||
$daemons[] = INSTALLDIR.'/scripts/queuedaemon.php';
|
||||
#$daemons[] = INSTALLDIR.'/scripts/queuedaemon.php';
|
||||
|
||||
if (Event::handle('GetValidDaemons', array(&$daemons))) {
|
||||
foreach ($daemons as $daemon) {
|
||||
|
Loading…
Reference in New Issue
Block a user