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

fix bug in types that int[0,1] were boolean #81

Merged

Conversation

MaxFedotov
Copy link
Contributor

@MaxFedotov MaxFedotov commented Nov 9, 2018

Hello,

there is some discrepancy between values in types\resource and proxysql. By default some of them are boolean in types, had [0,1] regexp checks in resouce and are defined as INT CHECK (negate_match_pattern IN (0,1)) in proxysql.
Because of it is impossible to set them in manifest

For example, setting "transaction_persistent": 0 for user will lead to:
Evaluation Error: Error while evaluating a Method call, Class[Db::Proxysql]: parameter 'mysql_users' index 0 entry 'app' entry 'transaction_persistent' expects a Boolean value, got Integer

and setting "transaction_persistent": false for user will lead to:
Failed to apply catalog: Parameter transaction_persistent failed on Proxy_mysql_user[app]: Invalid value false. Valid values match /[01]/.

@alexjfisher
Copy link
Member

@MaxFedotov Sorry, I merged #88 before seeing this PR also existed! Yours actually looks more complete. If you can rebase it, I'll look at getting it merged soon after.

@alexjfisher
Copy link
Member

And thanks for all your other PRs. I'll try to get them reviewed and progressed. If things are stalling, stop by the puppet community slack #voxpupuli channel or IRC Freenode #voxpupuli.

@bastelfreak bastelfreak added the bug Something isn't working label Mar 5, 2019
@dhoppe dhoppe requested a review from alexjfisher June 5, 2019 08:52
@dhoppe
Copy link
Member

dhoppe commented Jun 5, 2019

@alexjfisher This pull request is more strict than #88, because it expects a very specific value. In my opinion this pull request can be merged. Any objections?

@alexjfisher alexjfisher force-pushed the fix_boolean_in_proxysql_users branch from 1ce5fc0 to e7bcbf6 Compare July 4, 2019 12:39
@alexjfisher
Copy link
Member

@dhoppe Agreed. I've rebased again and will now merge.

@MaxFedotov Thanks!

@alexjfisher alexjfisher merged commit 8533918 into voxpupuli:master Jul 4, 2019
@MaxFedotov MaxFedotov deleted the fix_boolean_in_proxysql_users branch July 4, 2019 13:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants