-
-
Notifications
You must be signed in to change notification settings - Fork 499
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
Add new parameter autoconvert for rabbitmq_parameter #865
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks reasonable to me, provided it’s used carefully. Would it be good to make the parameter refer to autoconvert vs munge?
Good point @wyardley . I've renamed the parameter to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Would you mind squashing down to one commit in your branch?
Thanks, Will! It's in one commit now. |
Cool. Going to leave this open for a day or two in case anyone else wants to review / comment. I’ll try to cut a new release after merging this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
release 10.3.0: * Add new parameter autoconvert for rabbitmq_parameter (@joec4i) (voxpupuli#865) * Ensure :autoconvert is initialized before :value for rabbitmq_parameter (@joec4i) (voxpupuli#867) * modulesync 3.1.0 (@bastelfreak) (voxpupuli#864)
release 10.3.0: * Add new parameter autoconvert for rabbitmq_parameter (@joec4i) (voxpupuli#865) * Ensure :autoconvert is initialized before :value for rabbitmq_parameter (@joec4i) (voxpupuli#867) * modulesync 3.1.0 (@bastelfreak) (voxpupuli#864) * modulesync 4.0.0 (@bastelfreak) (voxpupuli#866)
* Add new parameter autoconvert for rabbitmq_parameter (@joec4i) (voxpupuli#865) * Ensure :autoconvert is initialized before :value for rabbitmq_parameter (@joec4i) (voxpupuli#867) * modulesync 3.1.0 (@bastelfreak) (voxpupuli#864) * modulesync 4.0.0 (@bastelfreak) (voxpupuli#866)
* Add new parameter autoconvert for rabbitmq_parameter (@joec4i) (voxpupuli#865) * Ensure :autoconvert is initialized before :value for rabbitmq_parameter (@joec4i) (voxpupuli#867) * modulesync 3.1.0 (@bastelfreak) (voxpupuli#864) * modulesync 4.0.0 (@bastelfreak) (voxpupuli#866)
Pull Request (PR) description
Add a new parameter
autoconvert
forrabbitmq_parameter
to allow users to disable auto type conversion from numeric strings to integers if needed.This Pull Request (PR) fixes the following issues
We have several
x-content-hash
exchanges which use a numeric string as the routing key. Due to themunge_value
implementation, the routing key would be converted to an integer.As a result, a valid payload to create a shovel as below
will be converted to
Because RabbitMQ doesn't accept exchange keys to be integers, it'll throw out validation errors:
This PR would allow the auto type conversion to be disabled and therefore numeric strings to be included in the RabbitMQ parameter payload if needed. The users would be responsible to ensure the right date types are used if
autoconvert
is set tofalse
.