Skip to content

Commit 386dfb0

Browse files
author
David R. MacIver
committed
more fixing of examples
1 parent 91968b9 commit 386dfb0

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

projects/examples/client/LogTail/src/examples/LogTail.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ public static int Main(string[] args) {
8080
string exchangeType = args[2];
8181
string routingKey = args[3];
8282

83-
using (IConnection conn = new ConnectionFactory().CreateConnection(serverAddress))
83+
using (IConnection conn = new ConnectionFactory(AmqpTcpEndpoint.Parse(serverAddress)).CreateConnection())
8484
{
8585
using (IModel ch = conn.CreateModel()) {
8686
Subscription sub;

projects/examples/client/SendString/src/examples/SendString.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ public static int Main(string[] args) {
7474
string routingKey = args[3];
7575
string message = args[4];
7676

77-
using (IConnection conn = new ConnectionFactory().CreateConnection(serverAddress))
77+
using (IConnection conn = new ConnectionFactory(AmqpTcpEndpoint.Parse(serverAddress)).CreateConnection())
7878
{
7979
using (IModel ch = conn.CreateModel()) {
8080

projects/examples/client/SingleGet/src/examples/SingleGet.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ public static int Main(string[] args) {
7474
string serverAddress = args[0];
7575
string queueName = args[1];
7676

77-
IConnection conn = new ConnectionFactory().CreateConnection(serverAddress);
77+
IConnection conn = new ConnectionFactory(AmqpTcpEndpoint.Parse(serverAddress)).CreateConnection();
7878
conn.ConnectionShutdown += new ConnectionShutdownEventHandler(LogConnClose);
7979

8080
using (IModel ch = conn.CreateModel()) {

0 commit comments

Comments
 (0)