Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MQTTnet.AspTestApp Fails to start #1980

Closed
grendo opened this issue Apr 28, 2024 · 1 comment · Fixed by #1981
Closed

MQTTnet.AspTestApp Fails to start #1980

grendo opened this issue Apr 28, 2024 · 1 comment · Fixed by #1981
Labels
bug Something isn't working

Comments

@grendo
Copy link

grendo commented Apr 28, 2024

I have the latest code from the repo and tried to start the MQTTnet.AspTestApp project to test websockets.
I had to add a handler to the program.cs as ServiceCollectionExtensions.AddHostedMqttServer crashes if it is null

builder.Services.AddMqttServer(config => {

});

After that the server started but in the web page you get
mqtt.min.js:5 WebSocket connection to 'ws://localhost:5049/mqtt' failed:

@grendo grendo added the bug Something isn't working label Apr 28, 2024
@chkr1011
Copy link
Collaborator

The argument check is indeed wrong. I will remove it so that it will support null again as it was originally intended.

I tested with mqttMultimeter and I can connect with URI: localhost:5000/mqtt

Do you have some logs from mqtt.min why the connection has failed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants