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

mysql_db: added zstd support #696

Merged
merged 1 commit into from
Jan 16, 2025

Conversation

Sergio-IME
Copy link
Contributor

@Sergio-IME Sergio-IME commented Jan 15, 2025

SUMMARY

Closes #594

Added support for zstd compressed dumps (.zst file extension), which can be faster and more efficient than the currently supported gzip/bz2/xz formats.

ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME

mysql_db

ADDITIONAL INFORMATION

Copy link

codecov bot commented Jan 15, 2025

Codecov Report

Attention: Patch coverage is 0% with 4 lines in your changes missing coverage. Please review.

Project coverage is 76.98%. Comparing base (022ed60) to head (fc610bf).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
plugins/modules/mysql_db.py 0.00% 2 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #696      +/-   ##
==========================================
- Coverage   79.54%   76.98%   -2.56%     
==========================================
  Files          32       20      -12     
  Lines        2811     2664     -147     
  Branches      701      678      -23     
==========================================
- Hits         2236     2051     -185     
- Misses        395      415      +20     
- Partials      180      198      +18     
Flag Coverage Δ
integration 76.35% <0.00%> (-0.19%) ⬇️
sanity ?
units ?

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@Andersson007 Andersson007 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Sergio-IME hi, thanks for the improvement!

I'm approving the PR as the implementation is the same as for the other formats.
Would be also great to add integration tests to somewhere in https://github.com/ansible-collections/community.mysql/tree/main/tests/integration/targets/test_mysql_db/tasks.
Would you be interested in doing it in another PR (or in this one if you want)?
Anyway, I don't see it as a blocker in this particular case.
Approved.

@laurent-indermuehle
Copy link
Collaborator

I don't think we test other compression algorithm either. So I'm merging this PR. Thanks @Sergio-IME for your contribution!
Thought it could be great to add integration tests that validate the compressed archive can restore tables once imported. This could be done in another PR.

@laurent-indermuehle laurent-indermuehle merged commit a45a0d0 into ansible-collections:main Jan 16, 2025
55 of 57 checks passed
@ajbonner
Copy link

Thank you so much for adding this @Sergio-IME 🙏

@Andersson007
Copy link
Collaborator

I think we could release after #697 if everybody is happy so user will get the features

@Andersson007
Copy link
Collaborator

released https://galaxy.ansible.com/ui/repo/published/community/mysql FYI
you can install it manually now or wait for the next ansible package minor release if you prefer that way

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

Successfully merging this pull request may close these issues.

mysql_db: support for zstd compression
5 participants