-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
PubSub subscription callback #6064
Comments
It seems that Paho supports a success callback on the call to subscribe. It should be possible to await that in the call in Mqtt over WS. |
Is there any possibility of this being done? The subscribe is not very useful without it. |
Any updates please as I am experiencing a similar issue in that my first Pub after subscribing to get the shadow state is not receiving data. If I wait and then manually trigger a pub I get the data. |
Good news. We've added |
@stocaaro I need to do this because I can only publish to a topic after being 100% connected with some subscriptions. |
Hello @LFMAKER, I added a reply to this question over on #2692. |
Is your feature request related to a problem? Please describe.
I need to send a message to an MQTT topic after subscribing to it, so I can hear the response. Currently, I'd have to set a dumb timeout to give the broker just a little time to process the subscription request
Describe the solution you'd like
A callback/promise/connection event for
PubSub.subscribe
Describe alternatives you've considered
I currently use a different MQTT library (the aws-iot-device-sdk), since it supports this sort of callback.
The text was updated successfully, but these errors were encountered: