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

Is it possible to use github.com/klauspost/compress instead of github.com/DataDog/zstd #799

Closed
hjweddie opened this issue Jun 17, 2023 · 5 comments · Fixed by #801
Closed

Comments

@hjweddie
Copy link
Contributor

github.com/DataDog/zstd is not compatible with arm64 platform and it relies on cgo and linux heavily.
We use arm64 graviton3 instance on aws and arm instances on other cloud provider heavily to reduce cost. We find that it could not compile when we upgrade github.com/go-mysql-org/go-mysql to lastest commit on master branch.

@lance6716
Copy link
Collaborator

lance6716 commented Jun 18, 2023

it's because github.com/klauspost/compress does not support older golang versions. may I ask what's your golang version in production?

and maybe we can provide two implementations which is controlled by golang version build tags. for old versions we can use github.com/DataDog/zstd which requires cgo.

and maybe a third implementation that will turn zstd operation into error when user has old golang versions and no available cgo

@hjweddie
Copy link
Contributor Author

we use go 1.20 and go1.19 in production.
Regards to golang release policy, we prefer to upgrade to new version. So that we suggest that go-mysql may support new golang version.

refers:
Release Policy
Each major Go release is supported until there are two newer major releases

@lance6716
Copy link
Collaborator

oh that's reasonable! what do you think @atercattus @dveeden

@hjweddie
Copy link
Contributor Author

It may be of great help for us, if it can be controlled by golang version build tags

@dveeden
Copy link
Collaborator

dveeden commented Jun 18, 2023

I think we can remove support for some older Go versions that don't have upstream support anymore and have a single implementation that works on all platforms.

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 a pull request may close this issue.

3 participants