forked from mirror/client_golang
Bump minimum required Go version to 1.16 (#1032)
Signed-off-by: Manuel Rüger <manuel@rueg.eu>
This commit is contained in:
parent
24172847e3
commit
46d3dd4e6c
|
@ -46,10 +46,6 @@ workflows:
|
||||||
client_golang:
|
client_golang:
|
||||||
jobs:
|
jobs:
|
||||||
# Refer to README.md for the currently supported versions.
|
# Refer to README.md for the currently supported versions.
|
||||||
- test:
|
|
||||||
name: go-1-15
|
|
||||||
go_version: "1.15"
|
|
||||||
run_lint: true
|
|
||||||
- test:
|
- test:
|
||||||
name: go-1-16
|
name: go-1-16
|
||||||
go_version: "1.16"
|
go_version: "1.16"
|
||||||
|
|
|
@ -1,3 +1,7 @@
|
||||||
|
## Unreleased
|
||||||
|
|
||||||
|
* [CHANGE] Minimum required Go version is now 1.16.
|
||||||
|
|
||||||
## 1.12.1 / 2022-01-29
|
## 1.12.1 / 2022-01-29
|
||||||
|
|
||||||
* [BUGFIX] Make the Go 1.17 collector concurrency-safe #969
|
* [BUGFIX] Make the Go 1.17 collector concurrency-safe #969
|
||||||
|
|
|
@ -10,7 +10,7 @@ This is the [Go](http://golang.org) client library for
|
||||||
instrumenting application code, and one for creating clients that talk to the
|
instrumenting application code, and one for creating clients that talk to the
|
||||||
Prometheus HTTP API.
|
Prometheus HTTP API.
|
||||||
|
|
||||||
__This library requires Go1.15 or later.__
|
__This library requires Go1.16 or later.__
|
||||||
|
|
||||||
## Important note about releases and stability
|
## Important note about releases and stability
|
||||||
|
|
||||||
|
|
2
go.mod
2
go.mod
|
@ -12,4 +12,4 @@ require (
|
||||||
google.golang.org/protobuf v1.28.0
|
google.golang.org/protobuf v1.28.0
|
||||||
)
|
)
|
||||||
|
|
||||||
go 1.15
|
go 1.16
|
||||||
|
|
|
@ -15,7 +15,6 @@ package collectors
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"runtime"
|
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/prometheus/client_golang/prometheus"
|
"github.com/prometheus/client_golang/prometheus"
|
||||||
|
@ -50,9 +49,7 @@ func TestDBStatsCollector(t *testing.T) {
|
||||||
"go_sql_wait_duration_seconds_total",
|
"go_sql_wait_duration_seconds_total",
|
||||||
"go_sql_max_idle_closed_total",
|
"go_sql_max_idle_closed_total",
|
||||||
"go_sql_max_lifetime_closed_total",
|
"go_sql_max_lifetime_closed_total",
|
||||||
}
|
"go_sql_max_idle_time_closed_total",
|
||||||
if runtime.Version() >= "go1.15" {
|
|
||||||
names = append(names, "go_sql_max_idle_time_closed_total")
|
|
||||||
}
|
}
|
||||||
type result struct {
|
type result struct {
|
||||||
found bool
|
found bool
|
||||||
|
|
Loading…
Reference in New Issue