Skip to content

Commit

Permalink
fix fmt & lint
Browse files Browse the repository at this point in the history
  • Loading branch information
hookokoko committed Dec 25, 2023
1 parent 04005b5 commit 5d79e6d
Show file tree
Hide file tree
Showing 15 changed files with 30 additions and 62 deletions.
2 changes: 0 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,6 @@ require (
go.etcd.io/etcd/client/pkg/v3 v3.5.7 // indirect
go.etcd.io/etcd/client/v3 v3.5.7 // indirect
go.etcd.io/etcd/server/v3 v3.5.5 // indirect
go.opentelemetry.io/contrib/propagators/b3 v1.10.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.10.0 // indirect
go.starlark.net v0.0.0-20211013185944-b0039bd2cfe3 // indirect
go.uber.org/multierr v1.8.0 // indirect
Expand All @@ -344,4 +343,3 @@ require (
)

replace google.golang.org/protobuf v1.28.1 => google.golang.org/protobuf v1.28.0

43 changes: 4 additions & 39 deletions go.sum

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion operator/pkg/apis/istio/v1alpha1/types.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions pilot/pkg/config/kube/ingress/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,10 @@ import (
// STRICT requires "kubernetes.io/ingress.class" == mesh.IngressClass
// DEFAULT allows Ingress without explicit class.
// In 1.1:
// - K8S_INGRESS_NS - namespace of the Gateway that will act as ingress.
// - labels of the gateway set to "app=ingressgateway" for node_port, service set to 'ingressgateway' (matching default install)
// If we need more flexibility - we can add it (but likely we'll deprecate ingress support first)
// - K8S_INGRESS_NS - namespace of the Gateway that will act as ingress.
// - labels of the gateway set to "app=ingressgateway" for node_port, service set to 'ingressgateway' (matching default install)
// If we need more flexibility - we can add it (but likely we'll deprecate ingress support first)
//
// -
var schemas = collection.SchemasFor(
collections.IstioNetworkingV1Alpha3Virtualservices,
Expand Down
7 changes: 4 additions & 3 deletions pilot/pkg/config/kube/ingressv1/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,10 @@ import (
// STRICT requires "kubernetes.io/ingress.class" == mesh.IngressClass
// DEFAULT allows Ingress without explicit class.
// In 1.1:
// - K8S_INGRESS_NS - namespace of the Gateway that will act as ingress.
// - labels of the gateway set to "app=ingressgateway" for node_port, service set to 'ingressgateway' (matching default install)
// If we need more flexibility - we can add it (but likely we'll deprecate ingress support first)
// - K8S_INGRESS_NS - namespace of the Gateway that will act as ingress.
// - labels of the gateway set to "app=ingressgateway" for node_port, service set to 'ingressgateway' (matching default install)
// If we need more flexibility - we can add it (but likely we'll deprecate ingress support first)
//
// -
var schemas = collection.SchemasFor(
collections.IstioNetworkingV1Alpha3Virtualservices,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ func TestRetry(t *testing.T) {
Retries: &networking.HTTPRetry{
// Explicitly not retrying.
Attempts: 2,
RetryOn: " some, ,fake , conditions, ,",
RetryOn: " some, ,fake , conditions, ,",
},
},
assertFunc: func(g *WithT, policy *envoyroute.RetryPolicy) {
Expand Down
3 changes: 2 additions & 1 deletion pilot/pkg/networking/dubbo/v1alpha1/debouncehelper.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ import (
"go.uber.org/atomic"
)

/**
/*
*
Copy From pilot/pkg/xds/discovery.go
*/
type debounceOptions struct {
Expand Down
1 change: 1 addition & 0 deletions pkg/kube/inject/inject_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -883,6 +883,7 @@ func TestAppendMultusNetwork(t *testing.T) {
}

for _, tc := range cases {
tc := tc
t.Run(tc.name, func(t *testing.T) {
t.Parallel()
actual := appendMultusNetwork(tc.in, "istio-cni")
Expand Down
6 changes: 3 additions & 3 deletions pkg/test/framework/components/stackdriver/google.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ import (
)

import (
"cloud.google.com/go/logging/apiv2/loggingpb"
"cloud.google.com/go/monitoring/apiv3/v2/monitoringpb"
cloudtracepb "cloud.google.com/go/trace/apiv1/tracepb"
cloudtrace "google.golang.org/api/cloudtrace/v1"
logging "google.golang.org/api/logging/v2"
monitoring "google.golang.org/api/monitoring/v3"
"google.golang.org/genproto/googleapis/api/metric"
"google.golang.org/genproto/googleapis/api/monitoredres"
cloudtracepb "google.golang.org/genproto/googleapis/devtools/cloudtrace/v1"
ltype "google.golang.org/genproto/googleapis/logging/type"
loggingpb "google.golang.org/genproto/googleapis/logging/v2"
monitoringpb "google.golang.org/genproto/googleapis/monitoring/v3"
)

import (
Expand Down
6 changes: 3 additions & 3 deletions pkg/test/framework/components/stackdriver/kube.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ import (

import (
"cloud.google.com/go/compute/metadata"
cloudtracepb "google.golang.org/genproto/googleapis/devtools/cloudtrace/v1"
"cloud.google.com/go/logging/apiv2/loggingpb"
"cloud.google.com/go/monitoring/apiv3/v2/monitoringpb"
cloudtracepb "cloud.google.com/go/trace/apiv1/tracepb"
ltype "google.golang.org/genproto/googleapis/logging/type"
loggingpb "google.golang.org/genproto/googleapis/logging/v2"
monitoringpb "google.golang.org/genproto/googleapis/monitoring/v3"
kubeApiCore "k8s.io/api/core/v1"
)

Expand Down
6 changes: 3 additions & 3 deletions pkg/test/framework/components/stackdriver/stackdriver.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
package stackdriver

import (
cloudtracepb "google.golang.org/genproto/googleapis/devtools/cloudtrace/v1"
loggingpb "google.golang.org/genproto/googleapis/logging/v2"
monitoringpb "google.golang.org/genproto/googleapis/monitoring/v3"
"cloud.google.com/go/logging/apiv2/loggingpb"
"cloud.google.com/go/monitoring/apiv3/v2/monitoringpb"
cloudtracepb "cloud.google.com/go/trace/apiv1/tracepb"
)

import (
Expand Down
2 changes: 1 addition & 1 deletion pkg/wasm/imagefetcher_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,7 @@ func newMockLayer(mediaType types.MediaType, contents map[string][]byte) (v1.Lay
if err := tw.WriteHeader(&tar.Header{
Name: filename,
Size: int64(len(content)),
Typeflag: tar.TypeRegA,
Typeflag: tar.TypeReg,
}); err != nil {
return nil, err
}
Expand Down
2 changes: 2 additions & 0 deletions security/pkg/credentialfetcher/fetcher_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ func TestNewCredFetcher(t *testing.T) {
// Disable token refresh for GCE VM credential fetcher.
plugin.SetTokenRotation(false)
for id, tc := range testCases {
tc := tc
id := id
t.Run(id, func(t *testing.T) {
t.Parallel()
cf, err := NewCredFetcher(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ import (

import (
privateca "cloud.google.com/go/security/privateca/apiv1"
"cloud.google.com/go/security/privateca/apiv1/privatecapb"
"google.golang.org/api/option"
privatecapb "google.golang.org/genproto/googleapis/cloud/security/privateca/v1"
"google.golang.org/protobuf/types/known/durationpb"
"istio.io/pkg/log"
"k8s.io/apimachinery/pkg/util/rand"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import (
)

import (
privatecapb "google.golang.org/genproto/googleapis/cloud/security/privateca/v1"
"cloud.google.com/go/security/privateca/apiv1/privatecapb"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
Expand Down

0 comments on commit 5d79e6d

Please sign in to comment.