more work on queue optimisations
This commit is contained in:
@@ -135,10 +135,25 @@ function notifier_run($argv, $argc){
|
||||
));
|
||||
if($data) {
|
||||
$result = zot_zot($hh['hubloc_callback'],$data);
|
||||
// zot_queue_item is not yet written
|
||||
// if(! $result['success'])
|
||||
// zot_queue_item();
|
||||
|
||||
// if immediate delivery failed, stick it in the queue to try again later.
|
||||
|
||||
if(! $result['success']) {
|
||||
$hash = random_string();
|
||||
q("insert into outq ( outq_hash, outq_account, outq_channel, outq_driver, outq_posturl, outq_async, outq_created, outq_updated, outq_notify, outq_msg )
|
||||
values ( '%s', %d, %d, '%s', '%s', %d, '%s', '%s', '%s', '%s' )",
|
||||
dbesc($hash),
|
||||
intval($s[0]['channel_account_id']),
|
||||
intval($s[0]['channel_id']),
|
||||
dbesc('zot'),
|
||||
dbesc($hh['hubloc_callback']),
|
||||
intval(1),
|
||||
dbesc(datetime_convert()),
|
||||
dbesc(datetime_convert()),
|
||||
dbesc($data),
|
||||
dbesc('')
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user