8000 Use IBasicProperties#SetPersistent · somnathzankar/rabbitmq-tutorials@b3ef133 · GitHub
[go: up one dir, main page]

Skip to content

Commit b3ef133

Browse files
author
Michael Klishin
committed
Use IBasicProperties#SetPersistent
1 parent 9669560 commit b3ef133

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dotnet/NewTask.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ public static void Main(string[] args)
1818
var body = Encoding.UTF8.GetBytes(message);
1919

2020
var properties = channel.CreateBasicProperties();
21-
properties.DeliveryMode = 2;
21+
properties.SetPersistent(true);
2222

2323
channel.BasicPublish("", "task_queue", properties, body);
2424
Console.WriteLine(" [x] Sent {0}", message);

0 commit comments

Comments
 (0)
0