mirror of
https://github.com/dotnet/MQTTnet.git
synced 2026-10-16 17:23:04 +08:00
removed dead code and make new connection context an opt in so kestrel 2.0 still works
This commit is contained in:
@@ -17,8 +17,12 @@ namespace MQTTnet.TestApp.AspNetCore2
|
||||
|
||||
public void ConfigureServices(IServiceCollection services)
|
||||
{
|
||||
var mqttServerOptions = new MqttServerOptionsBuilder().Build();
|
||||
services.AddHostedMqttServer(mqttServerOptions);
|
||||
var mqttServerOptions = new MqttServerOptionsBuilder()
|
||||
.WithoutDefaultEndpoint()
|
||||
.Build();
|
||||
services
|
||||
.AddHostedMqttServer(mqttServerOptions)
|
||||
.AddMqttConnectionHandler();
|
||||
}
|
||||
|
||||
// In class _Startup_ of the ASP.NET Core 2.0 project.
|
||||
|
||||
Reference in New Issue
Block a user