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

Bump go mod to 1.20 and go build to 1.20.4 #518

Merged
merged 1 commit into from
May 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ jobs:
build:
working_directory: /home/circleci/go/src/github.com/grafana/carbon-relay-ng
docker:
- image: cimg/go:1.20.3
- image: cimg/go:1.20.4
steps:
- checkout
- run: go install github.com/go-bindata/go-bindata/...@latest
Expand Down Expand Up @@ -166,7 +166,7 @@ jobs:

github_binaries:
docker:
- image: cimg/go:1.20.3
- image: cimg/go:1.20.4
steps:
- checkout
- run: curl -sfL https://goreleaser.com/static/run | bash
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
# unreleased

# v1.4.3: May 5, 2023
* Bump go mod version to 1.20 and update go images used to build carbon-relay-ng to 1.20.4 #518

# v1.4.2: April 19, 2023
* Update go images used to build carbon-relay-ng to 1.20.3 #517

Expand Down
20 changes: 10 additions & 10 deletions go-whisper/whisper.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,13 +59,13 @@ func parseRetentionPart(retentionPart string) (int, error) {
}

/*
Parse a retention definition as you would find in the storage-schemas.conf of a Carbon install.
Note that this only parses a single retention definition, if you have multiple definitions (separated by a comma)
you will have to split them yourself.
Parse a retention definition as you would find in the storage-schemas.conf of a Carbon install.
Note that this only parses a single retention definition, if you have multiple definitions (separated by a comma)
you will have to split them yourself.

ParseRetentionDef("10s:14d") Retention{10, 120960}
ParseRetentionDef("10s:14d") Retention{10, 120960}

See: http://graphite.readthedocs.org/en/1.0/config-carbon.html#storage-schemas-conf
See: http://graphite.readthedocs.org/en/1.0/config-carbon.html#storage-schemas-conf
*/
func ParseRetentionDef(retentionDef string) (*Retention, error) {
parts := strings.Split(retentionDef, ":")
Expand Down Expand Up @@ -128,10 +128,10 @@ func validateRetentions(retentions Retentions) error {
}

/*
A retention level.
A retention level.

Retention levels describe a given archive in the database. How detailed it is and how far back
it records.
Retention levels describe a given archive in the database. How detailed it is and how far back
it records.
*/
type Retention struct {
secondsPerPoint int
Expand Down Expand Up @@ -178,8 +178,8 @@ func (r retentionsByPrecision) Less(i, j int) bool {
}

/*
Implementation of modulo that works like Python
Thanks @timmow for this
Implementation of modulo that works like Python
Thanks @timmow for this
*/
func mod(a, b int) int {
return a - (b * int(math.Floor(float64(a)/float64(b))))
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/grafana/carbon-relay-ng

go 1.18
go 1.20

require (
cloud.google.com/go v0.18.1-0.20180119164648-b1067c1d21b5
Expand Down