Skip to content

Commit 0f1761f

Browse files
Merge pull request #807 from rabbitmq/resolver-factory
Use EndpointResolverFactory as indicated in XML comments
2 parents 6dad161 + 5405ac2 commit 0f1761f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

projects/RabbitMQ.Client/client/api/ConnectionFactory.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -355,7 +355,7 @@ public IAuthMechanismFactory AuthMechanismFactory(IList<string> mechanismNames)
355355
/// </exception>
356356
public IConnection CreateConnection()
357357
{
358-
return CreateConnection(EndpointResolverFactory(LocalEndpoints()), ClientProvidedName);
358+
return CreateConnection(ClientProvidedName);
359359
}
360360

361361
/// <summary>
@@ -419,7 +419,7 @@ public IConnection CreateConnection(IList<string> hostnames)
419419
public IConnection CreateConnection(IList<string> hostnames, string clientProvidedName)
420420
{
421421
IEnumerable<AmqpTcpEndpoint> endpoints = hostnames.Select(h => new AmqpTcpEndpoint(h, Port, Ssl));
422-
return CreateConnection(new DefaultEndpointResolver(endpoints), clientProvidedName);
422+
return CreateConnection(EndpointResolverFactory(endpoints), clientProvidedName);
423423
}
424424

425425
/// <summary>
@@ -461,7 +461,7 @@ public IConnection CreateConnection(IList<AmqpTcpEndpoint> endpoints)
461461
/// </exception>
462462
public IConnection CreateConnection(IList<AmqpTcpEndpoint> endpoints, string clientProvidedName)
463463
{
464-
return CreateConnection(new DefaultEndpointResolver(endpoints), clientProvidedName);
464+
return CreateConnection(EndpointResolverFactory(endpoints), clientProvidedName);
465465
}
466466

467467
/// <summary>

0 commit comments

Comments
 (0)