Can now set $config['queue']['stomp_persistent'] = false; to explicitly disable persistence when we queue items

This commit is contained in:
Brion Vibber
2010-01-28 09:52:35 -08:00
parent ffaaf9de4a
commit a868a523a5
2 changed files with 6 additions and 4 deletions

View File

@@ -174,12 +174,13 @@ class StompQueueManager extends QueueManager
$this->_connect();
// XXX: serialize and send entire notice
$props = array('created' => common_sql_now());
if (common_config('queue', 'stomp_persistent')) {
$props['persistent'] = 'true';
}
$result = $this->con->send($this->queueName($queue),
$msg, // BODY of the message
array ('created' => common_sql_now(),
'persistent' => 'true'));
$props);
if (!$result) {
common_log(LOG_ERR, "Error sending $rep to $queue queue");