Merge pull request #206 from stof/patch-1

Publish tasks as persistent messages in the php-amqp tutorial
This commit is contained in:
Michael Klishin 2019-03-12 20:11:39 +03:00 committed by GitHub
commit 4893925fcf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -33,7 +33,7 @@ if(empty($message))
$message = "Hello World!";
$exchange = new AMQPExchange($channel);
$exchange->publish($message, $routing_key);
$exchange->publish($message, $routing_key, AMQP_NOPARAM, array('delivery_mode' => 2));
echo " [x] Sent {$message}", PHP_EOL;