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

feat(compression): use klauspost zstd when cgo is not enabled #1706

Merged
merged 2 commits into from
May 27, 2021

Conversation

NamanJain8
Copy link
Contributor

@NamanJain8 NamanJain8 commented May 26, 2021

Use https://github.com/klauspost/compress ZSTD compression when CGO is not enabled.
Related to #1383


This change is Reviewable

@NamanJain8 NamanJain8 force-pushed the naman/klauspost-zstd branch from 55ee6cd to 1ec0af3 Compare May 26, 2021 11:45
Copy link
Contributor

@jarifibrahim jarifibrahim left a comment

Choose a reason for hiding this comment

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

Awesome @NamanJain8 ! Let's merge this once the build goes through.

Also, please run all the tests locally with CGO_ENABLED=0 . The tests currently run with CGO enabled.

@NamanJain8
Copy link
Contributor Author

NamanJain8 commented May 26, 2021

Let's merge this once the build goes through.

@danielmai can we check why the CI is not running on these PRs?

Also, please run all the tests locally with CGO_ENABLED=0 . The tests currently run with CGO enabled.

Done. All tests passed locally.

@NamanJain8 NamanJain8 merged commit b188600 into master May 27, 2021
@NamanJain8 NamanJain8 deleted the naman/klauspost-zstd branch May 27, 2021 10:08
NamanJain8 added a commit that referenced this pull request Jul 2, 2021
Use https://github.com/klauspost/compress ZSTD compression when CGO is not enabled.
Related to #1383

(cherry picked from commit b188600)
NamanJain8 pushed a commit that referenced this pull request Aug 25, 2021
…std (#1736)

Backports the changes from #1706 and #1709 to the v2 branch of badger.

For context, https://github.com/caddyserver/caddy uses https://github.com/smallstep/certificates which uses https://github.com/smallstep/nosql which uses badger.

See smallstep/nosql#12 for the discussion. It's not currently viable for smallstep to upgrade from v2 to v3 of badger, so it would be nice to backport this zstd change to the v2 branch to remove the implicit (yet optional) CGO dependency on Caddy.

I targeted the release/v2.2007 branch, I couldn't really see a more relevant branch to target, so I hope that's okay.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants