Skip to content

Commit

Permalink
Bump go and dependencies (#89)
Browse files Browse the repository at this point in the history
* Bump go and dependencies

---------

Signed-off-by: Gao Hongtao <[email protected]>
  • Loading branch information
hanahmily authored Jul 27, 2023
1 parent a362d2b commit 502610b
Show file tree
Hide file tree
Showing 31 changed files with 63 additions and 63 deletions.
26 changes: 13 additions & 13 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -49,7 +49,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
- name: Check out code into the Go module directory
uses: actions/checkout@v3
- name: Build
Expand All @@ -63,7 +63,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -78,7 +78,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -93,7 +93,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -108,7 +108,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -123,7 +123,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -144,7 +144,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -159,7 +159,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -174,7 +174,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -189,7 +189,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -204,7 +204,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand All @@ -219,7 +219,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v3
with:
go-version: 1.19
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
Expand Down
4 changes: 2 additions & 2 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ Release Notes.
- Fix errors in banyandb e2e test.

#### Chores
- Bump up golang to v1.19.
- Bump up golangci-lint to v1.50.0.
- Bump up golang to v1.20.
- Bump up golangci-lint to v1.53.3.
- Bump up skywalking-java-agent to v8.16.0.
- Bump up kustomize to v4.5.6.
- Bump up SkyWalking OAP to 9.5.0.
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ For more details, please read [Java agent injector](/docs/java-agent-injector.md
or

```
kubectl apply -k "github.com/apache/skywalking-swck/operator/config/default?ref=v0.7.0"
kubectl apply -k "github.com/apache/skywalking-swck/operator/config/default?ref=v0.8.0"
```

For more details, please refer to [deploy operator](docs/operator.md)
Expand All @@ -78,7 +78,7 @@ For more details, please refer to [deploy operator](docs/operator.md)
or

```
kubectl apply -k "github.com/apache/skywalking-swck/adapter/config?ref=v0.7.0"
kubectl apply -k "github.com/apache/skywalking-swck/adapter/config?ref=v0.8.0"
```

For more details, please read [Custom metrics adapter](docs/custom-metrics-adapter.md)
Expand Down
2 changes: 1 addition & 1 deletion adapter/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
# limitations under the License.

# Build the manager binary
FROM golang:1.19 as builder
FROM golang:1.20 as builder

WORKDIR /workspace
# Copy the Go Modules manifests
Expand Down
2 changes: 1 addition & 1 deletion adapter/config/namespaced/adapter/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ kind: Kustomization
images:
- name: metrics-adapter
newName: apache/skywalking-swck
newTag: v0.7.0
newTag: v0.8.0
4 changes: 2 additions & 2 deletions adapter/dist/LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ BSD-3-Clause licenses
golang.org/x/net v0.7.0 BSD-3-Clause
golang.org/x/oauth2 v0.4.0 BSD-3-Clause
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 BSD-3-Clause
golang.org/x/sys v0.5.0 BSD-3-Clause
golang.org/x/sys v0.10.0 BSD-3-Clause
golang.org/x/term v0.5.0 BSD-3-Clause
golang.org/x/text v0.7.0 BSD-3-Clause
golang.org/x/time v0.0.0-20220210224613-90d013bbcef8 BSD-3-Clause
Expand All @@ -122,7 +122,7 @@ MIT licenses
github.com/josharian/intern v1.0.0 MIT
github.com/json-iterator/go v1.1.12 MIT
github.com/mailru/easyjson v0.7.6 MIT
github.com/sirupsen/logrus v1.8.1 MIT
github.com/sirupsen/logrus v1.9.3 MIT
github.com/urfave/cli v1.22.1 MIT
go.uber.org/atomic v1.7.0 MIT
go.uber.org/multierr v1.6.0 MIT
Expand Down
6 changes: 3 additions & 3 deletions adapter/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/apache/skywalking-swck/adapter

go 1.19
go 1.20

require (
github.com/apache/skywalking-cli v0.0.0-20210209032327-04a0ce08990f
Expand Down Expand Up @@ -58,7 +58,7 @@ require (
github.com/prometheus/common v0.32.1 // indirect
github.com/prometheus/procfs v0.7.3 // indirect
github.com/russross/blackfriday/v2 v2.1.0 // indirect
github.com/sirupsen/logrus v1.8.1 // indirect
github.com/sirupsen/logrus v1.9.3 // indirect
github.com/spf13/cobra v1.4.0 // indirect
github.com/spf13/pflag v1.0.5 // indirect
go.etcd.io/etcd/api/v3 v3.5.1 // indirect
Expand All @@ -82,7 +82,7 @@ require (
golang.org/x/net v0.7.0 // indirect
golang.org/x/oauth2 v0.4.0 // indirect
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 // indirect
golang.org/x/sys v0.5.0 // indirect
golang.org/x/sys v0.10.0 // indirect
golang.org/x/term v0.5.0 // indirect
golang.org/x/text v0.7.0 // indirect
golang.org/x/time v0.0.0-20220210224613-90d013bbcef8 // indirect
Expand Down
8 changes: 5 additions & 3 deletions adapter/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -580,8 +580,9 @@ github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPx
github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE=
github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88=
github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0=
github.com/sirupsen/logrus v1.8.1 h1:dJKuHgqk1NNQlqoA6BTlM1Wf9DOH3NBjQyu0h9+AZZE=
github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0=
github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ=
github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ=
github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc=
github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA=
github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM=
Expand Down Expand Up @@ -927,8 +928,9 @@ golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.5.0 h1:MUK/U/4lj1t1oPg0HfuXDN/Z1wv31ZJ/YcPiGccS4DU=
golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.10.0 h1:SqMFp9UcQJZa+pmYuAKjd9xq1f0j5rLcDIk0mj4qAsA=
golang.org/x/sys v0.10.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/term v0.5.0 h1:n2a8QNdAb0sZNpU9R1ALUXBbY+w51fCQDN+7EdxNBsY=
Expand Down
2 changes: 1 addition & 1 deletion adapter/pkg/provider/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ func bufferEntity(buff []string, index int, requirement labels.Requirement, dec
return buff, nil
}

func (p *externalMetricsProvider) GetExternalMetric(ctx context.Context, namespace string, metricSelector labels.Selector,
func (p *externalMetricsProvider) GetExternalMetric(_ context.Context, namespace string, metricSelector labels.Selector,
info apiprovider.ExternalMetricInfo) (*external_metrics.ExternalMetricValueList, error) {
var md *swctlapi.MetricDefinition
for _, m := range p.metricDefines {
Expand Down
1 change: 1 addition & 0 deletions build/images/Dockerfile.release-bin
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
# limitations under the License.

FROM gcr.io/distroless/static:nonroot
WORKDIR /
COPY --chown=65532:65532 bin/manager-linux-amd64 /manager
COPY --chown=65532:65532 bin/adapter-linux-amd64 /adapter
USER 65532:65532
Expand Down
4 changes: 0 additions & 4 deletions golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,13 @@

linters:
enable:
- deadcode
- errcheck
- goconst
- revive
- ineffassign
- lll
- misspell
- structcheck
- unconvert
- varcheck
- govet
- goimports
- prealloc
Expand All @@ -49,6 +46,5 @@ run:
- dist
issues:
exclude:
# staticcheck
- 'SA1019: Package github.com/golang/protobuf/proto is deprecated: Use the "google.golang.org/protobuf/proto" package instead.'
- 'SA1019: Package github.com/golang/protobuf/jsonpb is deprecated: Use the "google.golang.org/protobuf/encoding/protojson" package instead.'
4 changes: 2 additions & 2 deletions hack/build/module.mk
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ include $(root_dir)/hack/build/base.mk

CONTROLLER_GEN_VERSION := v0.7.0
KUSTOMIZE_VERSION := v4.5.6
GOLANGCI_LINT_VERSION := v1.50.0
GOLANGCI_LINT_VERSION := v1.53.3

##@ Code quality and integrity

Expand All @@ -52,7 +52,7 @@ check: ## Check that the status

.PHONY: lint
lint: golangci-lint ## Lint codes
$(GOLANGCILINT) run --config $(root_dir)/golangci.yml
$(GOLANGCILINT) -v run --config $(root_dir)/golangci.yml

CONTROLLER_GEN = $(tool_bin)/controller-gen
.PHONY: controller-gen
Expand Down
2 changes: 1 addition & 1 deletion operator/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
# limitations under the License.

# Build the manager binary
FROM golang:1.19 as builder
FROM golang:1.20 as builder

WORKDIR /workspace
# Copy the Go Modules manifests
Expand Down
2 changes: 1 addition & 1 deletion operator/apis/operator/v1alpha1/banyandb_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ func (r *BanyanDB) ValidateCreate() error {
return r.validate()
}

func (r *BanyanDB) ValidateUpdate(old runtime.Object) error {
func (r *BanyanDB) ValidateUpdate(_ runtime.Object) error {
banyandbLog.Info("validate update", "name", r.Name)
return r.validate()
}
Expand Down
2 changes: 1 addition & 1 deletion operator/apis/operator/v1alpha1/fetcher_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func (r *Fetcher) ValidateCreate() error {
}

// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (r *Fetcher) ValidateUpdate(old runtime.Object) error {
func (r *Fetcher) ValidateUpdate(_ runtime.Object) error {
fetcherlog.Info("validate update", "name", r.Name)
return r.validate()
}
Expand Down
2 changes: 1 addition & 1 deletion operator/apis/operator/v1alpha1/javaagent_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ func (r *JavaAgent) ValidateCreate() error {
}

// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (r *JavaAgent) ValidateUpdate(old runtime.Object) error {
func (r *JavaAgent) ValidateUpdate(_ runtime.Object) error {
javaagentlog.Info("validate update", "name", r.Name)
return r.validate()
}
Expand Down
2 changes: 1 addition & 1 deletion operator/apis/operator/v1alpha1/oapserver_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func (r *OAPServer) ValidateCreate() error {
}

// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (r *OAPServer) ValidateUpdate(old runtime.Object) error {
func (r *OAPServer) ValidateUpdate(_ runtime.Object) error {
oapserverlog.Info("validate update", "name", r.Name)
return r.validate()
}
Expand Down
2 changes: 1 addition & 1 deletion operator/apis/operator/v1alpha1/oapserverconfig_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ func (r *OAPServerConfig) ValidateCreate() error {
}

// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (r *OAPServerConfig) ValidateUpdate(old runtime.Object) error {
func (r *OAPServerConfig) ValidateUpdate(_ runtime.Object) error {
oapserverconfiglog.Info("validate update", "name", r.Name)
return r.validate()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ func (r *OAPServerDynamicConfig) ValidateCreate() error {
}

// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (r *OAPServerDynamicConfig) ValidateUpdate(old runtime.Object) error {
func (r *OAPServerDynamicConfig) ValidateUpdate(_ runtime.Object) error {
oapserverdynamicconfiglog.Info("validate update", "name", r.Name)
return r.validate()
}
Expand Down
2 changes: 1 addition & 1 deletion operator/apis/operator/v1alpha1/satellite_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ func (r *Satellite) ValidateCreate() error {
}

// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (r *Satellite) ValidateUpdate(old runtime.Object) error {
func (r *Satellite) ValidateUpdate(_ runtime.Object) error {
satellitelog.Info("validate update", "name", r.Name)
return r.validate()
}
Expand Down
2 changes: 1 addition & 1 deletion operator/apis/operator/v1alpha1/storage_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ func (r *Storage) ValidateCreate() error {
}

// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (r *Storage) ValidateUpdate(old runtime.Object) error {
func (r *Storage) ValidateUpdate(_ runtime.Object) error {
storagelog.Info("validate update", "name", r.Name)
return r.valid()
}
Expand Down
2 changes: 1 addition & 1 deletion operator/apis/operator/v1alpha1/swagent_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func (r *SwAgent) ValidateCreate() error {
}

// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (r *SwAgent) ValidateUpdate(old runtime.Object) error {
func (r *SwAgent) ValidateUpdate(_ runtime.Object) error {
swagentlog.Info("validate update", "name", r.Name)
return nil
}
Expand Down
2 changes: 1 addition & 1 deletion operator/apis/operator/v1alpha1/ui_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ func (r *UI) ValidateCreate() error {
}

// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (r *UI) ValidateUpdate(old runtime.Object) error {
func (r *UI) ValidateUpdate(_ runtime.Object) error {
uilog.Info("validate update", "name", r.Name)
return r.validate()
}
Expand Down
2 changes: 1 addition & 1 deletion operator/config/manager/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ kind: Kustomization
images:
- name: controller
newName: apache/skywalking-swck
newTag: v0.7.0
newTag: v0.8.0
Loading

0 comments on commit 502610b

Please sign in to comment.