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

🎨 Allow to have multiple consumers for the same queue in 1 application and allow to optionally define queue name #6838

Conversation

sanderegg
Copy link
Member

@sanderegg sanderegg commented Nov 26, 2024

What do these changes do?

Before:

  • The RabbitMQ consumer was setup with a name unique to the application, but this prevents from having multiple ones in the same application
    After:
  • the ConsumerTag is returned when subscribing to a Exchange/Queue
  • unsubscribing a consumer from a Queue requires the ConsumerTag,
  • Fixes unsubscribing when the connection to the RabbitMQ service is already shutdown,
  • Upgraded derived services
  • After discussion with @matusdrobuliak66 adds option for non-exclusive queues to define a specific queue name

Related issue/s

How to test

Dev-ops checklist

@sanderegg sanderegg added the a:services-library issues on packages/service-libs label Nov 26, 2024
@sanderegg sanderegg added this to the Event Horizon milestone Nov 26, 2024
@sanderegg sanderegg self-assigned this Nov 26, 2024
Copy link

codecov bot commented Nov 26, 2024

Codecov Report

Attention: Patch coverage is 82.69231% with 9 lines in your changes missing coverage. Please review.

Project coverage is 87.70%. Comparing base (6fc9da1) to head (62c1083).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #6838      +/-   ##
==========================================
- Coverage   88.39%   87.70%   -0.69%     
==========================================
  Files        1550     1524      -26     
  Lines       61749    61106     -643     
  Branches     2164     2166       +2     
==========================================
- Hits        54580    53596     -984     
- Misses       6841     7180     +339     
- Partials      328      330       +2     
Flag Coverage Δ
integrationtests 60.78% <100.00%> (-4.01%) ⬇️
unittests 86.26% <82.69%> (-0.15%) ⬇️
Components Coverage Δ
api ∅ <ø> (∅)
pkg_aws_library 93.28% <ø> (ø)
pkg_dask_task_models_library 96.57% <ø> (ø)
pkg_models_library 91.16% <ø> (ø)
pkg_notifications_library 84.57% <ø> (ø)
pkg_postgres_database 87.52% <ø> (ø)
pkg_service_integration 70.00% <ø> (ø)
pkg_service_library 76.11% <79.31%> (-0.05%) ⬇️
pkg_settings_library 90.62% <ø> (ø)
pkg_simcore_sdk 85.36% <ø> (ø)
agent ∅ <ø> (∅)
api_server 89.72% <100.00%> (ø)
autoscaling 95.21% <ø> (ø)
catalog 90.57% <ø> (ø)
clusters_keeper 98.73% <ø> (ø)
dask_sidecar 91.26% <ø> (ø)
datcore_adapter 93.17% <ø> (ø)
director 76.49% <ø> (ø)
director_v2 85.60% <ø> (-5.42%) ⬇️
dynamic_scheduler 96.59% <ø> (ø)
dynamic_sidecar 89.75% <ø> (-0.04%) ⬇️
efs_guardian 90.12% <100.00%> (ø)
invitations 93.44% <ø> (ø)
osparc_gateway_server 85.49% <ø> (ø)
payments 92.76% <75.00%> (ø)
resource_usage_tracker 90.79% <100.00%> (ø)
storage 89.66% <ø> (ø)
webclient ∅ <ø> (∅)
webserver 88.66% <100.00%> (ø)

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6fc9da1...62c1083. Read the comment docs.

@sanderegg sanderegg marked this pull request as ready for review November 26, 2024 10:51
Copy link
Contributor

@GitHK GitHK left a comment

Choose a reason for hiding this comment

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

Nice solution. This was such a pain!

@sanderegg sanderegg force-pushed the redis-service-can-have-more-than-one-consumer branch from 2849646 to d7e70fb Compare November 26, 2024 12:31
Copy link
Contributor

@matusdrobuliak66 matusdrobuliak66 left a comment

Choose a reason for hiding this comment

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

Thanks!

@sanderegg sanderegg force-pushed the redis-service-can-have-more-than-one-consumer branch 2 times, most recently from f00f41f to ba34483 Compare November 26, 2024 13:49
@sanderegg sanderegg changed the title 🎨 Allow to have multiple consumers for the same queue in 1 application 🎨 Allow to have multiple consumers for the same queue in 1 application and allow to define queue name optionaly Nov 26, 2024
@sanderegg sanderegg changed the title 🎨 Allow to have multiple consumers for the same queue in 1 application and allow to define queue name optionaly 🎨 Allow to have multiple consumers for the same queue in 1 application and allow to optionally define queue name Nov 26, 2024
Copy link
Member

@pcrespov pcrespov left a comment

Choose a reason for hiding this comment

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

thx

@sanderegg sanderegg force-pushed the redis-service-can-have-more-than-one-consumer branch from ba34483 to 62c1083 Compare November 26, 2024 14:54
@sanderegg sanderegg merged commit bca766c into ITISFoundation:master Nov 26, 2024
37 checks passed
@sanderegg sanderegg deleted the redis-service-can-have-more-than-one-consumer branch November 26, 2024 14:55
Copy link

sonarcloud bot commented Nov 26, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a:services-library issues on packages/service-libs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants