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

Fix/mqtt default subscription #1510

Merged
merged 18 commits into from
Feb 25, 2025
Merged

Conversation

Umang01-hash
Copy link
Member

@Umang01-hash Umang01-hash commented Feb 20, 2025

Pull Request Template

Description:

  • Add IsConnected() method to all pub-sub clients so that during subscription we can have a check of it before actually trying to subscribe.
  • Add retryConnect to default MQTT client so that re-subscription happens after defaultClient reconnects.

Checklist:

  • I have formatted my code using goimport and golangci-lint.
  • All new code is covered by unit tests.
  • This PR does not decrease the overall code coverage.
  • I have reviewed the code comments and documentation for clarity.

Thank you for your contribution!

@vikash
Copy link
Contributor

vikash commented Feb 21, 2025

This looks unnecessary to be exposed. Subscribe can internally decide this. @Umang01-hash

@Umang01-hash
Copy link
Member Author

This looks unnecessary to be exposed. Subscribe can internally decide this. @Umang01-hash

Sure @vikash will do it internally.

Copy link
Contributor

@coolwednesday coolwednesday left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we are internally checking whether the client is connected or not...the IsConnected() function should be unexported.

@Umang01-hash
Copy link
Member Author

If we are internally checking whether the client is connected or not...the IsConnected() function should be unexported.

Sure done.

@Umang01-hash Umang01-hash merged commit b574630 into development Feb 25, 2025
17 checks passed
@Umang01-hash Umang01-hash deleted the fix/mqtt_default_subscription branch February 25, 2025 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants