Skip to content

Commit 787deac

Browse files
Merge pull request #904 from danielmarbach/rename-processing-concurrency-backport
Rename processing concurrency backport
2 parents 91e2cab + 13975a0 commit 787deac

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ public sealed class ConnectionFactory : ConnectionFactoryBase, IAsyncConnectionF
183183
/// </summary>
184184
/// <remarks>For concurrency greater than one this removes the guarantee that consumers handle messages in the order they receive them.
185185
/// In addition to that consumers need to be thread/concurrency safe.</remarks>
186-
public int ProcessingConcurrency { get; set; } = 1;
186+
public int ConsumerDispatchConcurrency { get; set; } = 1;
187187

188188
/// <summary>The host to connect to.</summary>
189189
public string HostName { get; set; } = "localhost";

projects/RabbitMQ.Client/client/impl/Connection.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,14 +110,14 @@ public Connection(IConnectionFactory factory, bool insist, IFrameHandler frameHa
110110
_factory = factory;
111111
_frameHandler = frameHandler;
112112

113-
int processingConcurrency = (factory as ConnectionFactory)?.ProcessingConcurrency ?? 1;
113+
int consumerDispatchConcurrency = (factory as ConnectionFactory)?.ConsumerDispatchConcurrency ?? 1;
114114
if (factory is IAsyncConnectionFactory asyncConnectionFactory && asyncConnectionFactory.DispatchConsumersAsync)
115115
{
116-
ConsumerWorkService = new AsyncConsumerWorkService(processingConcurrency);
116+
ConsumerWorkService = new AsyncConsumerWorkService(consumerDispatchConcurrency);
117117
}
118118
else
119119
{
120-
ConsumerWorkService = new ConsumerWorkService(processingConcurrency);
120+
ConsumerWorkService = new ConsumerWorkService(consumerDispatchConcurrency);
121121
}
122122

123123
_sessionManager = new SessionManager(this, 0);

projects/Unit/APIApproval.Approve.verified.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@ namespace RabbitMQ.Client
8282
public bool AutomaticRecoveryEnabled { get; set; }
8383
public System.Collections.Generic.IDictionary<string, object> ClientProperties { get; set; }
8484
public string ClientProvidedName { get; set; }
85+
public int ConsumerDispatchConcurrency { get; set; }
8586
public System.TimeSpan ContinuationTimeout { get; set; }
8687
public bool DispatchConsumersAsync { get; set; }
8788
public RabbitMQ.Client.AmqpTcpEndpoint Endpoint { get; set; }
@@ -91,7 +92,6 @@ namespace RabbitMQ.Client
9192
public System.TimeSpan NetworkRecoveryInterval { get; set; }
9293
public string Password { get; set; }
9394
public int Port { get; set; }
94-
public int ProcessingConcurrency { get; set; }
9595
public ushort RequestedChannelMax { get; set; }
9696
public System.TimeSpan RequestedConnectionTimeout { get; set; }
9797
public uint RequestedFrameMax { get; set; }

projects/Unit/TestAsyncConsumer.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public void TestBasicRoundtrip()
8585
[Test]
8686
public async Task TestBasicRoundtripConcurrent()
8787
{
88-
var cf = new ConnectionFactory{ DispatchConsumersAsync = true, ProcessingConcurrency = 2 };
88+
var cf = new ConnectionFactory{ DispatchConsumersAsync = true, ConsumerDispatchConcurrency = 2 };
8989
using(IConnection c = cf.CreateConnection())
9090
using(IModel m = c.CreateModel())
9191
{

projects/Unit/TestConsumer.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ public class TestConsumer
1313
[Test]
1414
public async Task TestBasicRoundtripConcurrent()
1515
{
16-
var cf = new ConnectionFactory{ ProcessingConcurrency = 2 };
16+
var cf = new ConnectionFactory{ ConsumerDispatchConcurrency = 2 };
1717
using(IConnection c = cf.CreateConnection())
1818
using(IModel m = c.CreateModel())
1919
{

0 commit comments

Comments
 (0)