mirror of
https://github.com/dotnet/MQTTnet.git
synced 2026-10-16 09:13:02 +08:00
Fix keep alive checks in server
This commit is contained in:
@@ -27,7 +27,9 @@
|
||||
<TextBox x:Name="ClientId"></TextBox>
|
||||
<TextBlock>Clean session:</TextBlock>
|
||||
<CheckBox x:Name="CleanSession" IsChecked="True"></CheckBox>
|
||||
|
||||
<TextBlock>Keep alive interval:</TextBlock>
|
||||
<TextBox x:Name="KeepAliveInterval" Text="5"></TextBox>
|
||||
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<RadioButton x:Name="UseTcp" IsChecked="True" GroupName="connection">TCP</RadioButton>
|
||||
<RadioButton x:Name="UseWs" GroupName="connection">WS</RadioButton>
|
||||
|
||||
@@ -103,7 +103,8 @@ namespace MQTTnet.TestApp.UniversalWindows
|
||||
};
|
||||
|
||||
options.CleanSession = CleanSession.IsChecked == true;
|
||||
|
||||
options.KeepAlivePeriod = TimeSpan.FromSeconds(double.Parse(KeepAliveInterval.Text));
|
||||
|
||||
try
|
||||
{
|
||||
if (_mqttClient != null)
|
||||
|
||||
Reference in New Issue
Block a user