editing composite queue selectors in explorer

View: New views
7 Messages — Rating Filter:   Alert me  

editing composite queue selectors in explorer

by Bryan Talbot :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Editing of a composite queue binding's message selector seems to be broken.  

Changing the selector from one value to another value doesn't produce any errors; however, messages are still routed using the old value.  The only ways I have found to make the change take effect are to save the config and restart the router, or to delete the binding and recreate it with the new selector.

Other changes made from explorer seem to be dynamic ... is this one supposed to be as well?

Re: editing composite queue selectors in explorer

by Bryan Talbot :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Looks like this problem extends to CLI and not just editing selectors from explorer.  Changes seem to be allowed, but they don't take affect until the router is restarted.


router1/sys$queuemanager/composite-queues/myq/queue-bindings/qEU> lc
Entity:      Queue Binding
Description: Queue Binding

Properties for this Entity:

Name                                    Current Value
--------------------------------------------------------------
change-destination                      true
generate-new-message-id                 false
message-selector                        countryCode IN ('FR', 'DE')

router1/sys$queuemanager/composite-queues/myq/queue-bindings/qEU> set message-selector "countryCode IN ('FR', 'DE', 'TR')"
router1/sys$queuemanager/composite-queues/myq/queue-bindings/qEU> lc
Entity:      Queue Binding
Description: Queue Binding

Properties for this Entity:

Name                                    Current Value
--------------------------------------------------------------
change-destination                      true
generate-new-message-id                 false
message-selector                        countryCode IN ('FR', 'DE', 'TR')

Re: editing composite queue selectors in explorer

by IIT Software :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

SwiftMQ Explorer uses CLI internally. You can change any property dynamically (and the change take effect immediately) if it is not read-only.

In this particular case we did not intend to let you change the message selector or the other attributes of a binding (there is no handler to perform a change), rather we want that you to just delete and recreate the binding. The problem is just that we did not declare the properties read-only... Will be changed for the next release.

Re: editing composite queue selectors in explorer

by Bryan Talbot :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

What is the recommended way to update a composite queue's bindings without losing any messages?  I believe that if I remove the binding and then re-add it with the new selector, any messages processed during that time will not get into the (then unbound) destination.

The least good solution is to stop all message production to the composite queue.

If there was a way to dynamically (and atomically) update the queue binding?  That would be sufficient for my needs.

Another option would be to allow for multiple bindings to the same destination with different selectors.  This would allow me to just keep adding new bindings instead of needing to update an existing one.

-Bryan

Re: editing composite queue selectors in explorer

by IIT Software :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Bryan Talbot wrote:
I believe that if I remove the binding and then re-add it with the new selector, any messages processed during that time will not get into the (then unbound) destination.
Correct.

Bryan Talbot wrote:
The least good solution is to stop all message production to the composite queue.
There is no other way currently if you want to be absolutely sure to lose no message. You could create a short CLI script to delete and recreate a binding. At least there would be minimal delay between the 2 commands if you execute it with clis.

Bryan Talbot wrote:
Another option would be to allow for multiple bindings to the same destination with different selectors.  This would allow me to just keep adding new bindings instead of needing to update an existing one.
The queue name is the name of the binding and it must be unique, sorry...

Re: editing composite queue selectors in explorer

by IIT Software :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

This has been fixed in 7.5.0, released today. You can now dynamically change selectors.

Re: editing composite queue selectors in explorer

by batalbot :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thank you for making this dynamically changeable.  This is a much better solution than making it not editable at all.

-Bryan