Added option for how many subscriptions to send in a single call to t… (#1209)

* Added option for how many subscriptions to send in a single call to the server.  aws iotcore limits this to 8

* Split subscription messages up to 8 at a time when reconnecting
This commit is contained in:
scottbrogden-iheartmedia
2021-09-19 12:41:33 +02:00
committed by GitHub
parent fcab0d5cf0
commit d01d859227
4 changed files with 66 additions and 13 deletions
@@ -1,4 +1,4 @@
using System;
using System;
using MQTTnet.Client.Options;
using MQTTnet.Server;
@@ -68,7 +68,13 @@ namespace MQTTnet.Extensions.ManagedClient
options(_clientOptionsBuilder);
return this;
}
public ManagedMqttClientOptionsBuilder WithMaxSubcribeUnsubscribeMessagesAtOnce(int? value)
{
_options.MaxSubcribeUnsubscribeMessagesAtOnce = value;
return this;
}
public ManagedMqttClientOptions Build()
{
if (_clientOptionsBuilder != null)