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

NOISSUE - Use RabbitMQ as MQTT broker #2695

Merged
merged 16 commits into from
Feb 26, 2025
Merged

Conversation

rodneyosodo
Copy link
Member

What type of PR is this?

This is a feature because it adds the following functionality: Add RabbitMQ as a MQTT broker.

What does this do?

The changes update the MQTT adapter and Docker configurations across the project. In the MQTT adapter, new configuration fields, a connection interceptor, and enhanced publisher/forwarder logic have been introduced, including authentication and QoS support. Docker-related files have been modified to integrate RabbitMQ as the MQTT broker, with updated environment variables, deployment documentation, and RabbitMQ-specific settings. Additional improvements include new tracing middleware for MQTT forwarding, updated dependency versions, and comprehensive tests for the MQTT pub/sub functionality using Docker.

Which issue(s) does this PR fix/relate to?

Have you included tests for your changes?

Yes, I have included tests for my changes. I have tested MQTT pubsub, COAP pubsub and HTTP pub. WS will be fixed in another PR

Did you document any new/modified feature?

Notes

@rodneyosodo rodneyosodo requested a review from a team as a code owner February 10, 2025 11:41
@rodneyosodo rodneyosodo force-pushed the rabbitmq branch 3 times, most recently from 49dfbb5 to 518b59e Compare February 10, 2025 11:48
Copy link

codecov bot commented Feb 10, 2025

Codecov Report

Attention: Patch coverage is 46.95652% with 122 lines in your changes missing coverage. Please review.

Project coverage is 27.66%. Comparing base (df0f906) to head (f16e7ab).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
pkg/messaging/mqtt/pubsub.go 71.83% 27 Missing and 13 partials ⚠️
mqtt/forwarder.go 0.00% 31 Missing ⚠️
mqtt/tracing/forwarder.go 0.00% 31 Missing ⚠️
pkg/messaging/mqtt/publisher.go 23.07% 18 Missing and 2 partials ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main    #2695       +/-   ##
===========================================
- Coverage   42.01%   27.66%   -14.35%     
===========================================
  Files         343       72      -271     
  Lines       47699     8504    -39195     
===========================================
- Hits        20039     2353    -17686     
+ Misses      25475     5979    -19496     
+ Partials     2185      172     -2013     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@rodneyosodo rodneyosodo force-pushed the rabbitmq branch 3 times, most recently from 1fa3a37 to e98d585 Compare February 11, 2025 10:29
@dborovcanin
Copy link
Collaborator

@rodneyosodo Please rebase.

@rodneyosodo rodneyosodo force-pushed the rabbitmq branch 4 times, most recently from d12c628 to dbf3819 Compare February 17, 2025 14:52
@rodneyosodo rodneyosodo force-pushed the rabbitmq branch 3 times, most recently from eb10e13 to 3af54d6 Compare February 19, 2025 13:33
@dborovcanin
Copy link
Collaborator

@felixgateru Please review and test this one.

felixgateru
felixgateru previously approved these changes Feb 20, 2025
Signed-off-by: Rodney Osodo <[email protected]>
This reverts commit 87db3e6.

Signed-off-by: Rodney Osodo <[email protected]>
Signed-off-by: Rodney Osodo <[email protected]>
Use rabbitMQ alpine rather than management-alpine since we are enabling
that feature using config files

Signed-off-by: Rodney Osodo <[email protected]>
Signed-off-by: Rodney Osodo <[email protected]>
The interceptor adds the correct credentials to the upstream MQTT broker

Signed-off-by: Rodney Osodo <[email protected]>
@dborovcanin dborovcanin merged commit 56829c1 into absmach:main Feb 26, 2025
6 of 8 checks passed
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.

3 participants