From 37b2fa2d47a8a3133cf7bf95b5dc3942ce45cd51 Mon Sep 17 00:00:00 2001 From: bogcon Date: Fri, 17 May 2024 14:48:27 +0300 Subject: [PATCH] Upgraded linter, github actions, dependencies --- .github/workflows/build.yml | 13 +- .golangci-lint.yml | 2 +- Makefile | 2 +- docs/xconf.drawio | 586 +++++++++++++++++++++++++++++- docs/xconf.svg | 4 +- go.mod | 37 +- go.sum | 93 ++--- loader_consul_test.go | 4 +- loader_etcd_test.go | 6 +- scripts/Dockerfile.etcdtls.github | 4 +- scripts/setup_dockers_deb.sh | 4 +- scripts/setup_dockers_local.sh | 4 +- 12 files changed, 674 insertions(+), 85 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2624d19..7bc6cdd 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -13,13 +13,13 @@ jobs: timeout-minutes: 10 strategy: matrix: - go-version: [1.20.x, 1.21.x] + go-version: [1.21.x, 1.22.x] platform: [ubuntu-latest, macos-latest, windows-latest] runs-on: ${{ matrix.platform }} steps: - name: Install Go - uses: actions/setup-go@v4 + uses: actions/setup-go@v5 with: go-version: ${{ matrix.go-version }} @@ -27,7 +27,7 @@ jobs: uses: actions/checkout@v4 - name: Load cached dependencies - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ~/go/pkg/mod key: ${{ runner.os }}-go-${{ matrix.go-version }}-${{ hashFiles('**/go.sum') }} @@ -48,7 +48,7 @@ jobs: timeout-minutes: 10 runs-on: ubuntu-latest - container: golang:1.21.4-bullseye + container: golang:1.22.1-bullseye steps: - name: Checkout code @@ -78,7 +78,8 @@ jobs: run: ./scripts/teardown_dockers.sh - name: Upload coverage to coveralls.io - uses: shogo82148/actions-goveralls@v1 + uses: coverallsapp/github-action@v2 with: - path-to-profile: cover-integration.out + file: cover-integration.out flag-name: integration-test + fail-on-error: false diff --git a/.golangci-lint.yml b/.golangci-lint.yml index 2b4b285..34b03b3 100644 --- a/.golangci-lint.yml +++ b/.golangci-lint.yml @@ -1,5 +1,5 @@ run: - deadline: 5m + timeout: 5m tests: true linters: diff --git a/Makefile b/Makefile index c779b14..52a1d05 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -LINTER_VERSION=v1.55.2 +LINTER_VERSION=v1.58.1 LINTER=./bin/golangci-lint ifeq ($(OS),Windows_NT) LINTER=./bin/golangci-lint.exe diff --git a/docs/xconf.drawio b/docs/xconf.drawio index 8f97e60..b78f558 100644 --- a/docs/xconf.drawio +++ b/docs/xconf.drawio @@ -1 +1,585 @@ -7V3bctu2Fv0azSQP9vB+ebRsp8lp0mbiTNqelzO0REtsKFKl6Djq1x+AJCgSIEhIJEBKRjvTmuBVwNp7r30BMNNvNz9/Sbzt+lO89MOZpix/zvS7maZpim6B/8GWfd5iaXbesEqCZd6kHhoegn/9olEpWp+Dpb+rXZjGcZgG23rjIo4if5HW2rwkiV/qlz3FYf2tW2/lEw0PCy8kW/8Iluk6b3VM5dD+3g9Wa/RmVSnOPHqL76skfo6K9800XVWNufkuP73x0LOK63drbxm/VJr0+5l+m8Rxmv+1+Xnrh7BvUbfl972jnC2/O/GjlOUG48v79T8P//0WbP6Ov+/j55v/vX9/peVP+eGFzz76GVYInjffwk9O90U3Wf88w++ch0HkX62L/rgBl6jX4IfMDxeAv1bZ/2+12c08iFI/efIWPjycz9GzH5PyMtSCGm7j6ClYoWbwax6JS4mbwVXbQ5tW+3Bt9xJsQi8CR/OnOEofijMKOPbCYBWBvxc+/EzQ8MNP0gBA46Y4sQmWS3j1fLEOwuVHD/Qa7OpdCoYeHc3XcRL8C57sheCUChrA6SQtgG4otSse4J3F2xN/B675jMZPxZo+eT9rF370dmnRsIjD0Nvugsfsl8AbN16yCqJ5nKbxprhonW7QBz0FYXgbh3GS9Yj+zjDnlpt9aBJ/9ytnFM1RXKXoqUr7vfHu7l4t70Byopb9DTvO/0kFplrCHagRP974abIHlxQ3WIWAFApELw5fDtKoGUXbuiKJVqF4vEIBrMoHl+/6AhSGF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jtlaymZDkGBVmaNl5pWgeABtpeCRwmMTRlB1aVeNv1p3jpwyv+Dw== \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/docs/xconf.svg b/docs/xconf.svg index 146dad9..b39546f 100644 --- a/docs/xconf.svg +++ b/docs/xconf.svg @@ -1,4 +1,4 @@ - + -

«interface»
Config

«interface»...
+ Get (key: string, defaultValue: any): any
DefaultConfig
DefaultConfig
- loader: Loader
- reloadInterval: time.Duration
- loader: Loader...
+ Get (key: string, defaultValue: any): any
+ RegisterObserver (obs: ConfigObserver)
+ Close (): error
+ Get (key: string, defaultValue: any)...

«interface»
Loader

«interface»...
+ Load (): (map[string]any, error)
«use»
«use»
JSONFileLoader
JSONFileLoader
JSONReaderLoader
JSONReaderLoader
YAMLFileLoader
YAMLFileLoader
YAMLReaderLoader
YAMLReaderLoader
TOMLFileLoader
TOMLFileLoader
TOMLReaderLoader
TOMLReaderLoader
PropertiesFileLoader
PropertiesFileLoader
PropertiesBytesLoader
PropertiesBytesLoader
IniFileLoader
IniFileLoader
DotEnvFileLoader
DotEnvFileLoader
«factory»
FileLoader
«factory»...
«instantiate»
«instantia...
EnvLoader
EnvLoader
PlainLoader
PlainLoader
FlagSetLoader
FlagSetLoader
DotEnvReaderLoader
DotEnvReaderLoader
ConsulLoader
ConsulLoader
EtcdLoader
EtcdLoader
«composite»
MultiLoader
«composite»...
- loaders: []Loader
- allowKeyOverwrite: bool
- loaders: []Loader...
«decorator»
FileCacheLoader
«decorator»...
- loader: Loader {file}
- loader: Loader {file}
«decorator»
FlattenLoader
«decorator»...
- loader: Loader
- loader: Loader
«decorator»
AlterValueLoader
«decorator»...
- loader: Loader
- transformer: AlterValueFunc
- loader: Loader...
«decorator»
IgnoreErrorLoader
«decorator»...
- loader: Loader
- loader: Loader
«decorator»
FilterKVLoader
«decorator»...
- loader: Loader
- fiters: []FilterKV
- loader: Loader...
NopConfig
NopConfig
MockConfig
MockConfig
«interface»
FilterKV
«interface»...
+ IsAllowed(key: string, value: any): bool
+ Type(): FilterType
+ IsAllowed(key: string, value: any):...
«use»
«use»
«enumeration»
FilterType
«enumeration»...
FilterTypeWhitelist
FilterTypeBlacklist
FilterTypeWhitelis...
«use»
«use»
FilterKVWhitelistFunc
FilterKVWhitelistFunc
FilterKVBlacklistFunc
FilterKVBlacklistFunc
(c) 2022 ActForGood
(c) 2022 ActForGood
AlterValueFunc
AlterValueFunc
«use»
«use»
ToStringList
ToStringList
ToIntList
ToIntList
«decorator»
AliasLoader
«decorator»...
- loader: Loader
- loader: Loader
Text is not SVG - cannot display
\ No newline at end of file +

«interface»
Config

«interface»...
+ Get (key: string, defaultValue: any): any
DefaultConfig
DefaultConfig
- loader: Loader
- reloadInterval: time.Duration
- loader: Loader...
+ Get (key: string, defaultValue: any): any
+ RegisterObserver (obs: ConfigObserver)
+ Close (): error
+ Get (key: string, defaultValue: any)...

«interface»
Loader

«interface»...
+ Load (): (map[string]any, error)
«use»
«use»
JSONFileLoader
JSONFileLoader
JSONReaderLoader
JSONReaderLoader
YAMLFileLoader
YAMLFileLoader
YAMLReaderLoader
YAMLReaderLoader
TOMLFileLoader
TOMLFileLoader
TOMLReaderLoader
TOMLReaderLoader
PropertiesFileLoader
PropertiesFileLoader
PropertiesBytesLoader
PropertiesBytesLoader
IniFileLoader
IniFileLoader
DotEnvFileLoader
DotEnvFileLoader
«factory»
FileLoader
«factory»...
«instantiate»
«instantia...
EnvLoader
EnvLoader
PlainLoader
PlainLoader
FlagSetLoader
FlagSetLoader
DotEnvReaderLoader
DotEnvReaderLoader
ConsulLoader
ConsulLoader
EtcdLoader
EtcdLoader
«composite»
MultiLoader
«composite»...
- loaders: []Loader
- allowKeyOverwrite: bool
- loaders: []Loader...
«decorator»
FileCacheLoader
«decorator»...
- loader: Loader {file}
- loader: Loader {file}
«decorator»
FlattenLoader
«decorator»...
- loader: Loader
- loader: Loader
«decorator»
AlterValueLoader
«decorator»...
- loader: Loader
- transformer: AlterValueFunc
- loader: Loader...
«decorator»
IgnoreErrorLoader
«decorator»...
- loader: Loader
- loader: Loader
«decorator»
FilterKVLoader
«decorator»...
- loader: Loader
- fiters: []FilterKV
- loader: Loader...
NopConfig
NopConfig
MockConfig
MockConfig
«interface»
FilterKV
«interface»...
+ IsAllowed(key: string, value: any): bool
+ Type(): FilterType
+ IsAllowed(key: string, value: any):...
«use»
«use»
«enumeration»
FilterType
«enumeration»...
FilterTypeWhitelist
FilterTypeBlacklist
FilterTypeWhitelis...
«use»
«use»
FilterKVWhitelistFunc
FilterKVWhitelistFunc
FilterKVBlacklistFunc
FilterKVBlacklistFunc
(c) 2022 ActForGood
(c) 2022 ActForGood
AlterValueFunc
AlterValueFunc
«use»
«use»
ToStringList
ToStringList
ToIntList
ToIntList
«decorator»
AliasLoader
«decorator»...
- loader: Loader
- loader: Loader
Text is not SVG - cannot display
\ No newline at end of file diff --git a/go.mod b/go.mod index 73c8745..bcee520 100644 --- a/go.mod +++ b/go.mod @@ -1,17 +1,17 @@ module github.com/actforgood/xconf -go 1.20 +go 1.21 require ( - github.com/actforgood/xerr v1.3.0 - github.com/actforgood/xlog v1.5.0 + github.com/actforgood/xerr v1.4.0 + github.com/actforgood/xlog v1.6.0 github.com/joho/godotenv v1.5.1 github.com/magiconair/properties v1.8.7 - github.com/pelletier/go-toml/v2 v2.1.0 - github.com/spf13/cast v1.5.1 - go.etcd.io/etcd/api/v3 v3.5.10 - go.etcd.io/etcd/client/v3 v3.5.10 - google.golang.org/grpc v1.59.0 + github.com/pelletier/go-toml/v2 v2.2.2 + github.com/spf13/cast v1.6.0 + go.etcd.io/etcd/api/v3 v3.5.13 + go.etcd.io/etcd/client/v3 v3.5.13 + google.golang.org/grpc v1.64.0 gopkg.in/ini.v1 v1.67.0 gopkg.in/yaml.v3 v3.0.1 ) @@ -19,18 +19,17 @@ require ( require ( github.com/coreos/go-semver v0.3.1 // indirect github.com/coreos/go-systemd/v22 v22.5.0 // indirect - github.com/getsentry/sentry-go v0.25.0 // indirect + github.com/getsentry/sentry-go v0.27.0 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang/protobuf v1.5.3 // indirect - go.etcd.io/etcd/client/pkg/v3 v3.5.10 // indirect + github.com/golang/protobuf v1.5.4 // indirect + go.etcd.io/etcd/client/pkg/v3 v3.5.13 // indirect go.uber.org/multierr v1.11.0 // indirect - go.uber.org/zap v1.26.0 // indirect - golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.14.0 // indirect - golang.org/x/text v0.14.0 // indirect - google.golang.org/genproto v0.0.0-20231106174013-bbf56f31fb17 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231106174013-bbf56f31fb17 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17 // indirect - google.golang.org/protobuf v1.31.0 // indirect + go.uber.org/zap v1.27.0 // indirect + golang.org/x/net v0.25.0 // indirect + golang.org/x/sys v0.20.0 // indirect + golang.org/x/text v0.15.0 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20240515191416-fc5f0ca64291 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240515191416-fc5f0ca64291 // indirect + google.golang.org/protobuf v1.34.1 // indirect ) diff --git a/go.sum b/go.sum index b6afc3c..51d5a38 100644 --- a/go.sum +++ b/go.sum @@ -1,7 +1,7 @@ -github.com/actforgood/xerr v1.3.0 h1:v3u8d5uMh2jud8wt7/hQe3UG+kutsOBV8FfeYGhMZ8A= -github.com/actforgood/xerr v1.3.0/go.mod h1:rPtRaXUESl0b69ZzQ+2GTx9f+idPEfkahTZ67fNfbSQ= -github.com/actforgood/xlog v1.5.0 h1:yGLvwWqFJOAvyXl6r0IHRENEav8kNBA0waP0QZq624E= -github.com/actforgood/xlog v1.5.0/go.mod h1:OrXGjEI/KYSE02XnqJaHOiwQQz6wZ7aKRO4IM091WC4= +github.com/actforgood/xerr v1.4.0 h1:sJ5JtGc0Q+5j8JwNpztrZ4un/F2PAUvPyfofawuiKFw= +github.com/actforgood/xerr v1.4.0/go.mod h1:rPtRaXUESl0b69ZzQ+2GTx9f+idPEfkahTZ67fNfbSQ= +github.com/actforgood/xlog v1.6.0 h1:+7q/MeIsPZRa6j7VmIlUkvRjVmYyB5OsrH7RrmxfYwA= +github.com/actforgood/xlog v1.6.0/go.mod h1:sL5K1M1VO3mYlpo1KYpdGhwHePyTZPzLR8cCv6i680k= github.com/coreos/go-semver v0.3.1 h1:yi21YpKnrx1gt5R+la8n5WgS0kCrsPp33dmEyHReZr4= github.com/coreos/go-semver v0.3.1/go.mod h1:irMmmIw/7yzSRPWryHsK7EYSg09caPQL03VsM8rvUec= github.com/coreos/go-systemd/v22 v22.5.0 h1:RrqgGjYQKalulkV8NGVIfkXQf6YYmOyiJKk8iXXhfZs= @@ -9,57 +9,66 @@ github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSV github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/frankban/quicktest v1.14.4 h1:g2rn0vABPOOXmZUj+vbmUp0lPoXEMuhTpIluN0XL9UY= -github.com/getsentry/sentry-go v0.25.0 h1:q6Eo+hS+yoJlTO3uu/azhQadsD8V+jQn2D8VvX1eOyI= -github.com/getsentry/sentry-go v0.25.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= +github.com/frankban/quicktest v1.14.6 h1:7Xjx+VpznH+oBnejlPUj8oUpdxnVs4f8XU8WnHkI4W8= +github.com/frankban/quicktest v1.14.6/go.mod h1:4ptaffx2x8+WTWXmUCuVU6aPUX1/Mz7zb5vbUoiM6w0= +github.com/getsentry/sentry-go v0.27.0 h1:Pv98CIbtB3LkMWmXi4Joa5OOcwbmnX88sF5qbK3r3Ps= +github.com/getsentry/sentry-go v0.27.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= +github.com/go-errors/errors v1.4.2/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= -github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= -github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= -github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= +github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= +github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= +github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= +github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/joho/godotenv v1.5.1 h1:7eLL/+HRGLY0ldzfGMeQkb7vMd0as4CfYvUVzLqw0N0= github.com/joho/godotenv v1.5.1/go.mod h1:f4LDr5Voq0i2e/R5DDNOoa2zzDfwtkZa6DnEwAbqwq4= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= +github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= +github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0VQdvPDY= github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= -github.com/pelletier/go-toml/v2 v2.1.0 h1:FnwAJ4oYMvbT/34k9zzHuZNrhlz48GB3/s6at6/MHO4= -github.com/pelletier/go-toml/v2 v2.1.0/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc= +github.com/pelletier/go-toml/v2 v2.2.2 h1:aYUidT7k73Pcl9nb2gScu7NSrKCSHIDE89b3+6Wq+LM= +github.com/pelletier/go-toml/v2 v2.2.2/go.mod h1:1t835xjRzz80PqgE6HHgN2JOsmgYu/h4qDAS4n929Rs= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= +github.com/pingcap/errors v0.11.4/go.mod h1:Oi8TUi2kEtXXLMJk9l1cGmz20kV3TaQ0usTwv5KuLY8= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= +github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8= -github.com/spf13/cast v1.5.1 h1:R+kOtfhWQE6TVQzY+4D7wJLBgkdVasCEFxSUBYBYIlA= -github.com/spf13/cast v1.5.1/go.mod h1:b9PdjNptOpzXr7Rq1q9gJML/2cdGQAo69NKzQ10KN48= +github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= +github.com/spf13/cast v1.6.0 h1:GEiTHELF+vaR5dhz3VqZfFSzZjYbgeKDpBxQVS4GYJ0= +github.com/spf13/cast v1.6.0/go.mod h1:ancEpBxwJDODSW/UG4rDrAqiKolqNNh2DX3mk86cAdo= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= +github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= -github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= +github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= +github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -go.etcd.io/etcd/api/v3 v3.5.10 h1:szRajuUUbLyppkhs9K6BRtjY37l66XQQmw7oZRANE4k= -go.etcd.io/etcd/api/v3 v3.5.10/go.mod h1:TidfmT4Uycad3NM/o25fG3J07odo4GBB9hoxaodFCtI= -go.etcd.io/etcd/client/pkg/v3 v3.5.10 h1:kfYIdQftBnbAq8pUWFXfpuuxFSKzlmM5cSn76JByiT0= -go.etcd.io/etcd/client/pkg/v3 v3.5.10/go.mod h1:DYivfIviIuQ8+/lCq4vcxuseg2P2XbHygkKwFo9fc8U= -go.etcd.io/etcd/client/v3 v3.5.10 h1:W9TXNZ+oB3MCd/8UjxHTWK5J9Nquw9fQBLJd5ne5/Ao= -go.etcd.io/etcd/client/v3 v3.5.10/go.mod h1:RVeBnDz2PUEZqTpgqwAtUd8nAPf5kjyFyND7P1VkOKc= -go.uber.org/goleak v1.2.0 h1:xqgm/S+aQvhWFTtR0XK3Jvg7z8kGV8P4X14IzwN3Eqk= +go.etcd.io/etcd/api/v3 v3.5.13 h1:8WXU2/NBge6AUF1K1gOexB6e07NgsN1hXK0rSTtgSp4= +go.etcd.io/etcd/api/v3 v3.5.13/go.mod h1:gBqlqkcMMZMVTMm4NDZloEVJzxQOQIls8splbqBDa0c= +go.etcd.io/etcd/client/pkg/v3 v3.5.13 h1:RVZSAnWWWiI5IrYAXjQorajncORbS0zI48LQlE2kQWg= +go.etcd.io/etcd/client/pkg/v3 v3.5.13/go.mod h1:XxHT4u1qU12E2+po+UVPrEeL94Um6zL58ppuJWXSAB8= +go.etcd.io/etcd/client/v3 v3.5.13 h1:o0fHTNJLeO0MyVbc7I3fsCf6nrOqn5d+diSarKnB2js= +go.etcd.io/etcd/client/v3 v3.5.13/go.mod h1:cqiAeY8b5DEEcpxvgWKsbLIWNM/8Wy2xJSDMtioMcoI= +go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= +go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= -go.uber.org/zap v1.26.0 h1:sI7k6L95XOKS281NhVKOFCUNIvv9e0w4BF8N3u+tCRo= -go.uber.org/zap v1.26.0/go.mod h1:dtElttAiwGvoJ/vj4IwHBS/gXsEu/pZ50mUIRWuG0so= +go.uber.org/zap v1.27.0 h1:aJMhYGrd5QSmlpLMr2MftRKl7t8J8PTZPA732ud/XR8= +go.uber.org/zap v1.27.0/go.mod h1:GB2qFLM7cTU87MWRP2mPIjqfIDnGu+VIO4V/SdhGo2E= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= @@ -69,20 +78,20 @@ golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM= -golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= +golang.org/x/net v0.25.0 h1:d/OCCoBEUq33pjydKrGQhw7IlUPI2Oylr+8qLx49kac= +golang.org/x/net v0.25.0/go.mod h1:JkAGAh7GEvH74S6FOH42FLoXpXbE/aqXSrIQjXgsiwM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= -golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.20.0 h1:Od9JTbYCk261bKm4M/mw7AklTlFYIa0bIp9BgSm1S8Y= +golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= -golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= +golang.org/x/text v0.15.0 h1:h1V/4gjBv8v9cjcR6+AR5+/cIYK5N/WAgiv4xlsEtAk= +golang.org/x/text v0.15.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= @@ -91,18 +100,14 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/genproto v0.0.0-20231106174013-bbf56f31fb17 h1:wpZ8pe2x1Q3f2KyT5f8oP/fa9rHAKgFPr/HZdNuS+PQ= -google.golang.org/genproto v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:J7XzRzVy1+IPwWHZUzoD0IccYZIrXILAQpc+Qy9CMhY= -google.golang.org/genproto/googleapis/api v0.0.0-20231106174013-bbf56f31fb17 h1:JpwMPBpFN3uKhdaekDpiNlImDdkUAyiJ6ez/uxGaUSo= -google.golang.org/genproto/googleapis/api v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:0xJLfVdJqpAPl8tDg1ujOCGzx6LFLttXT5NhllGOXY4= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17 h1:Jyp0Hsi0bmHXG6k9eATXoYtjd6e2UzZ1SCn/wIupY14= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17/go.mod h1:oQ5rr10WTTMvP4A36n8JpR1OrO1BEiV4f78CneXZxkA= -google.golang.org/grpc v1.59.0 h1:Z5Iec2pjwb+LEOqzpB2MR12/eKFhDPhuqW91O+4bwUk= -google.golang.org/grpc v1.59.0/go.mod h1:aUPDwccQo6OTjy7Hct4AfBPD1GptF4fyUjIkQ9YtF98= -google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= -google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= -google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/genproto/googleapis/api v0.0.0-20240515191416-fc5f0ca64291 h1:4HZJ3Xv1cmrJ+0aFo304Zn79ur1HMxptAE7aCPNLSqc= +google.golang.org/genproto/googleapis/api v0.0.0-20240515191416-fc5f0ca64291/go.mod h1:RGnPtTG7r4i8sPlNyDeikXF99hMM+hN6QMm4ooG9g2g= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240515191416-fc5f0ca64291 h1:AgADTJarZTBqgjiUzRgfaBchgYB3/WFTC80GPwsMcRI= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240515191416-fc5f0ca64291/go.mod h1:EfXuqaE1J41VCDicxHzUDm+8rk+7ZdXzHV0IhO/I6s0= +google.golang.org/grpc v1.64.0 h1:KH3VH9y/MgNQg1dE7b3XfVK0GsPSIzJwdF617gUSbvY= +google.golang.org/grpc v1.64.0/go.mod h1:oxjF8E3FBnjp+/gVFYdWacaLDx9na1aqy9oovLpxQYg= +google.golang.org/protobuf v1.34.1 h1:9ddQBjfCyZPOHPUiPxpYESBLc+T8P3E+Vo4IbKZgFWg= +google.golang.org/protobuf v1.34.1/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA= diff --git a/loader_consul_test.go b/loader_consul_test.go index db6fdff..8758a1b 100644 --- a/loader_consul_test.go +++ b/loader_consul_test.go @@ -452,7 +452,7 @@ func testConsulLoaderWithCache(t *testing.T) { } serverCallsCnt := 0 - svr := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { + svr := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, _ *http.Request) { w.Header().Set("Content-Type", "application/json") w.WriteHeader(http.StatusOK) if serverCallsCnt < len(contentByCall) { @@ -619,7 +619,7 @@ func benchmarkConsulLoader(format string, withCache bool) func(b *testing.B) { b.Helper() content := consulResponseContent[format][true] key := consulKeys[format] - svr := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { + svr := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, _ *http.Request) { w.Header().Set("Content-Type", "application/json") w.WriteHeader(http.StatusOK) _, _ = fmt.Fprintln(w, content) diff --git a/loader_etcd_test.go b/loader_etcd_test.go index cde9d76..b045cad 100644 --- a/loader_etcd_test.go +++ b/loader_etcd_test.go @@ -385,7 +385,7 @@ func testEtcdLoaderWithAuth(t *testing.T) { authenticateCallsCnt := 0 authUsr, authPwd := "john-doe", "some-secret-pwd" authSvr := etcdAuthServer{ - authenticateCallback: func(ctx context.Context, req *pb.AuthenticateRequest) (*pb.AuthenticateResponse, error) { + authenticateCallback: func(_ context.Context, req *pb.AuthenticateRequest) (*pb.AuthenticateResponse, error) { authenticateCallsCnt++ assertEqual(t, authUsr, req.Name) assertEqual(t, authPwd, req.Password) @@ -401,7 +401,7 @@ func testEtcdLoaderWithAuth(t *testing.T) { key := etcdKeys[format] content := etcdResponseKeys[format][withPrefix] kvSvr := etcdKVServer{ - rangeCallback: func(ctx context.Context, req *pb.RangeRequest) (*pb.RangeResponse, error) { + rangeCallback: func(_ context.Context, req *pb.RangeRequest) (*pb.RangeResponse, error) { assertEqual(t, key, string(req.Key)) return &pb.RangeResponse{ @@ -593,7 +593,7 @@ func benchmarkEtcdLoader(format string, withWatcher bool) func(b *testing.B) { content := etcdResponseKeys[format][true] key := etcdKeys[format] kvSvr := etcdKVServer{ - rangeCallback: func(ctx context.Context, rr *pb.RangeRequest) (*pb.RangeResponse, error) { + rangeCallback: func(_ context.Context, _ *pb.RangeRequest) (*pb.RangeResponse, error) { return &pb.RangeResponse{ Kvs: content, More: false, diff --git a/scripts/Dockerfile.etcdtls.github b/scripts/Dockerfile.etcdtls.github index 7951dd5..9e80ca0 100644 --- a/scripts/Dockerfile.etcdtls.github +++ b/scripts/Dockerfile.etcdtls.github @@ -1,6 +1,6 @@ -FROM alpine:3.18.4 +FROM alpine:3.19.1 -ARG ETCD_VER=v3.5.10 +ARG ETCD_VER=v3.5.13 ARG DOWNLOAD_URL=https://github.com/etcd-io/etcd/releases/download RUN mkdir -p /tmp/etcd-download RUN apk --no-cache add curl diff --git a/scripts/setup_dockers_deb.sh b/scripts/setup_dockers_deb.sh index 5f57731..347e1a8 100755 --- a/scripts/setup_dockers_deb.sh +++ b/scripts/setup_dockers_deb.sh @@ -77,7 +77,7 @@ network=$(docker inspect --format '{{json .NetworkSettings.Networks}}' "${hostNa echo ">>> network = ${network}" debug "Run Consul Docker Image" -DOCKER_CONSUL_IMAGE_VER=consul:1.15.4 +DOCKER_CONSUL_IMAGE_VER=hashicorp/consul:1.18.1 docker pull -q $DOCKER_CONSUL_IMAGE_VER docker run -d \ --name=xconf-consul \ @@ -87,7 +87,7 @@ docker run -d \ $DOCKER_CONSUL_IMAGE_VER debug "Run Etcd Docker Image" -ETCD_VER=v3.5.10 +ETCD_VER=v3.5.13 DOCKER_ETCD_IMAGE_VER=quay.io/coreos/etcd:${ETCD_VER} docker pull -q $DOCKER_ETCD_IMAGE_VER docker run -d \ diff --git a/scripts/setup_dockers_local.sh b/scripts/setup_dockers_local.sh index 4606ab5..48425dd 100755 --- a/scripts/setup_dockers_local.sh +++ b/scripts/setup_dockers_local.sh @@ -12,8 +12,8 @@ if [ "$local" != "local" ]; then exit 0 # we're not locally fi -DOCKER_CONSUL_IMAGE="consul:1.15.4" -DOCKER_ETCD_IMAGE="quay.io/coreos/etcd:v3.5.10" +DOCKER_CONSUL_IMAGE="hashicorp/consul:1.18.1" +DOCKER_ETCD_IMAGE="quay.io/coreos/etcd:v3.5.13" SCRIPT_PATH=$(dirname "$(readlink -f "$0")") # setUpLocalDocker ensures docker containers are up and running.