You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I connect to external RabbitMQ which provide pool of channel to connect, but should connect only to one, if fail then use another in pool.
For example: queue name 'queueN' where N is integer from 1 to 9. Should try to connecto to 'queue1' if fail then try to connect to 'queue2' etc.
During connection can be received next error:
RESOURCE_LOCKED - cannot obtain exclusive access to locked queue 'queue1' in vhost 'app'. It could be originally declared on another connection or the exclusive property value does not match that of the original...
Is it possible to implement it somehow, I thought about possibility to inherit from RabbitQueue and setup 'name' as property which return generated queue name, like:
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I connect to external RabbitMQ which provide pool of channel to connect, but should connect only to one, if fail then use another in pool.
For example: queue name 'queueN' where N is integer from 1 to 9. Should try to connecto to 'queue1' if fail then try to connect to 'queue2' etc.
During connection can be received next error:
Is it possible to implement it somehow, I thought about possibility to inherit from RabbitQueue and setup 'name' as property which return generated queue name, like:
but need somehow catch such error properly, then update 'num' and reconnect qith new name.
Any ideas how to implement such feature?
Beta Was this translation helpful? Give feedback.
All reactions