Kong / kubernetes-telemetry

Go library for telemetry in Kong's Kubernetes products
Apache License 2.0
5 stars 2 forks source link

chore(go): introduce usage of Go toolchain #189

Closed programmer04 closed 1 year ago

programmer04 commented 1 year ago

What this PR does / why we need it:

Embrace native toolchain management introduced in Go 1.21.0. Moreover do not rely on the hardcoded Go version in GH workflows that has to be updated manually, use the version defined in go.mod instead, read more.

To conclude when a new version of Go is released only update in go.mod to have the newest (and the same) version everywhere used (even locally).

Special notes for your reviewer:

Probably in the future usage of actions/setup-go@v4 to set version based on go.mod can be ditched too, because the Go toolchain ensures the right version automatically. For now, it's required because GH runners have an older version of Go that does not support toolchain features.