Skip to content

feat: Combine multiple grants into one while checking state #1376

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

Closed
wants to merge 1 commit into from

Conversation

fionera
Copy link

@fionera fionera commented Mar 18, 2021

Currently every grant line stands for itself, this isnt corrent since MySQL can split these up into multiple GRANT statements. This change combines them before checking for diff

Fixes: https://tickets.puppetlabs.com/browse/MODULES-10856

@fionera fionera requested a review from a team as a code owner March 18, 2021 16:19
@CLAassistant
Copy link

CLAassistant commented Mar 18, 2021

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@fionera fionera force-pushed the main branch 4 times, most recently from 7a5ca29 to 393d03c Compare March 18, 2021 20:00
@codecov-io
Copy link

Codecov Report

Merging #1376 (393d03c) into main (7acb8b5) will increase coverage by 4.57%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1376      +/-   ##
==========================================
+ Coverage   50.33%   54.90%   +4.57%     
==========================================
  Files          22       22              
  Lines        1055     1060       +5     
==========================================
+ Hits          531      582      +51     
+ Misses        524      478      -46     
Impacted Files Coverage Δ
lib/puppet/provider/mysql_grant/mysql.rb 15.38% <0.00%> (-1.12%) ⬇️
lib/facter/mysql_server_id.rb 37.50% <0.00%> (-50.00%) ⬇️
lib/puppet/provider/mysql_user/mysql.rb 87.41% <0.00%> (-0.18%) ⬇️
...ppet/provider/mysql_login_path/mysql_login_path.rb 90.72% <0.00%> (+58.76%) ⬆️

Continue to review full report at Codecov.

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

@pmcmaw
Copy link
Contributor

pmcmaw commented Apr 26, 2021

Hey @fionera

I would like to thank you for taking the time submitting this PR. Would you mind adding in a test for this functionality, so we can easily confirm in the future when merging other code and regressions can be highlighted quickly.

Many thanks
Puppet IAC Team.

@fuyar
Copy link
Contributor

fuyar commented Jul 23, 2021

Pinging @fionera, hopefully you can add a quick test to get this merged !
Thanks

@daianamezdrea
Copy link
Contributor

Hi @fionera, closing this as I merged 1428

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants