Skip to content

Commit

Permalink
Merge pull request #39 from ecordell/k127
Browse files Browse the repository at this point in the history
bump kube dependencies for 1.27
  • Loading branch information
ecordell committed Aug 9, 2023
2 parents 45ed61d + 7b3974a commit 6005d29
Show file tree
Hide file tree
Showing 10 changed files with 146 additions and 166 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ jobs:
- uses: "actions/checkout@v3"
- uses: "actions/setup-go@v3"
with:
go-version: "~1.19"
go-version: "~1.20"
- uses: "authzed/actions/go-test@main"
18 changes: 1 addition & 17 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
- uses: "actions/checkout@v3"
- uses: "actions/setup-go@v3"
with:
go-version: "~1.19"
go-version: "~1.20"
- uses: "authzed/actions/gofumpt@main"
- uses: "authzed/actions/go-generate@main"
- uses: "authzed/actions/golangci-lint@main"
Expand All @@ -27,19 +27,3 @@ jobs:
- uses: "actions/checkout@v3"
- uses: "authzed/actions/yaml-lint@main"
- uses: "authzed/actions/markdown-lint@main"

# TODO: enable when public
# codeql:
# name: "Analyze with CodeQL"
# runs-on: "ubuntu-latest"
# permissions:
# actions: "read"
# contents: "read"
# security-events: "write"
# strategy:
# fail-fast: false
# matrix:
# language: ["go"]
# steps:
# - uses: "actions/checkout@v3"
# - uses: "authzed/actions/codeql@main"
4 changes: 2 additions & 2 deletions component/ensure_component_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ func TestEnsureServiceHandler(t *testing.T) {
"example.com/component": "the-main-service-component",
},
Annotations: map[string]string{
hashKey: "n5d8h56h6dhc7h96h8h545h96q",
hashKey: "n649h58dh598h654hc4hc9hbbh689q",
},
}},
},
Expand All @@ -93,7 +93,7 @@ func TestEnsureServiceHandler(t *testing.T) {
"example.com/component": "the-main-service-component",
},
Annotations: map[string]string{
hashKey: "n5d8h56h6dhc7h96h8h545h96q",
hashKey: "n649h58dh598h654hc4hc9hbbh689q",
},
},
}, &corev1.Service{ObjectMeta: metav1.ObjectMeta{
Expand Down
19 changes: 11 additions & 8 deletions fileinformer/file_informer.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ func NewFileInformerFactory(log logr.Logger) (*Factory, error) {
}, nil
}

// Start starts watching the files defined byt the informers.
// Start starts watching the files defined by the informers.
func (f *Factory) Start(stopCh <-chan struct{}) {
f.Lock()
defer f.Unlock()
Expand All @@ -58,6 +58,9 @@ func (f *Factory) Start(stopCh <-chan struct{}) {
}
}

// Shutdown stops watching the files defined by the informers.
func (f *Factory) Shutdown() {}

// ForResource will create an informer for a specific file.
func (f *Factory) ForResource(gvr schema.GroupVersionResource) informers.GenericInformer {
f.Lock()
Expand Down Expand Up @@ -165,7 +168,7 @@ func (f *FileSharedIndexInformer) AddEventHandler(handler cache.ResourceEventHan
return f.AddEventHandlerWithResyncPeriod(handler, f.defaultEventHandlerResyncPeriod)
}

func (f *FileSharedIndexInformer) AddEventHandlerWithResyncPeriod(handler cache.ResourceEventHandler, resyncPeriod time.Duration) (cache.ResourceEventHandlerRegistration, error) {
func (f *FileSharedIndexInformer) AddEventHandlerWithResyncPeriod(handler cache.ResourceEventHandler, _ time.Duration) (cache.ResourceEventHandlerRegistration, error) {
f.RLock()
if f.started {
panic("cannot add event handlers after informer has started")
Expand All @@ -180,7 +183,7 @@ func (f *FileSharedIndexInformer) AddEventHandlerWithResyncPeriod(handler cache.
}

// RemoveEventHandler implements cache.SharedInformer
func (*FileSharedIndexInformer) RemoveEventHandler(handle cache.ResourceEventHandlerRegistration) error {
func (*FileSharedIndexInformer) RemoveEventHandler(_ cache.ResourceEventHandlerRegistration) error {
// TODO implement me
panic("unimplemented")
}
Expand Down Expand Up @@ -212,7 +215,7 @@ func (f *FileSharedIndexInformer) Run(stopCh <-chan struct{}) {
// do an initial read
f.RLock()
for _, h := range f.handlers {
h.OnAdd(fileName)
h.OnAdd(fileName, true)
}
f.RUnlock()

Expand Down Expand Up @@ -253,7 +256,7 @@ func (f *FileSharedIndexInformer) Run(stopCh <-chan struct{}) {
if event.Has(fsnotify.Write) || event.Has(fsnotify.Create) {
f.RLock()
for _, h := range f.handlers {
h.OnAdd(fileName)
h.OnAdd(fileName, false)
}
f.RUnlock()
}
Expand Down Expand Up @@ -303,12 +306,12 @@ func (f *FileSharedIndexInformer) LastSyncResourceVersion() string {
panic("implement me")
}

func (f *FileSharedIndexInformer) SetWatchErrorHandler(handler cache.WatchErrorHandler) error {
func (f *FileSharedIndexInformer) SetWatchErrorHandler(_ cache.WatchErrorHandler) error {
// TODO implement me
panic("implement me")
}

func (f *FileSharedIndexInformer) AddIndexers(indexers cache.Indexers) error {
func (f *FileSharedIndexInformer) AddIndexers(_ cache.Indexers) error {
// TODO implement me
panic("implement me")
}
Expand All @@ -318,7 +321,7 @@ func (f *FileSharedIndexInformer) GetIndexer() cache.Indexer {
panic("implement me")
}

func (f *FileSharedIndexInformer) SetTransform(handler cache.TransformFunc) error {
func (f *FileSharedIndexInformer) SetTransform(_ cache.TransformFunc) error {
// TODO implement me
panic("implement me")
}
2 changes: 1 addition & 1 deletion fileinformer/file_informer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ type MockEventHandlers struct {

var _ cache.ResourceEventHandler = &MockEventHandlers{}

func (m *MockEventHandlers) OnAdd(obj interface{}) {
func (m *MockEventHandlers) OnAdd(obj interface{}, _ bool) {
m.Lock()
defer m.Unlock()
m.Called(obj)
Expand Down
71 changes: 37 additions & 34 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -9,54 +9,56 @@ require (
github.com/go-logr/logr v1.2.3
github.com/maxbrunsfeld/counterfeiter/v6 v6.5.0
github.com/prometheus/client_golang v1.14.0
github.com/stretchr/testify v1.8.0
github.com/stretchr/testify v1.8.1
golang.org/x/exp v0.0.0-20220823124025-807a23277127
golang.org/x/sync v0.0.0-20220819030929-7fc1605a5dde
k8s.io/api v0.26.0
k8s.io/apiextensions-apiserver v0.26.0
k8s.io/apimachinery v0.26.0
k8s.io/apiserver v0.26.0
k8s.io/client-go v0.26.0
k8s.io/component-base v0.26.0
k8s.io/controller-manager v0.26.0
k8s.io/klog/v2 v2.80.1
k8s.io/utils v0.0.0-20221128185143-99ec85e7a448
golang.org/x/sync v0.1.0
k8s.io/api v0.27.2
k8s.io/apiextensions-apiserver v0.27.2
k8s.io/apimachinery v0.27.2
k8s.io/apiserver v0.27.2
k8s.io/client-go v0.27.2
k8s.io/component-base v0.27.2
k8s.io/controller-manager v0.27.2
k8s.io/klog/v2 v2.90.1
k8s.io/utils v0.0.0-20230209194617-a36077c30491
mvdan.cc/gofumpt v0.3.1
sigs.k8s.io/controller-runtime v0.14.1
)

require (
github.com/NYTimes/gziphandler v1.1.1 // indirect
github.com/antlr/antlr4/runtime/Go/antlr v1.4.10 // indirect
github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/blang/semver/v4 v4.0.0 // indirect
github.com/cenkalti/backoff/v4 v4.1.3 // indirect
github.com/coreos/go-semver v0.3.0 // indirect
github.com/coreos/go-systemd/v22 v22.3.2 // indirect
github.com/coreos/go-systemd/v22 v22.4.0 // indirect
github.com/emicklei/go-restful/v3 v3.9.0 // indirect
github.com/evanphx/json-patch v4.12.0+incompatible // indirect
github.com/evanphx/json-patch/v5 v5.6.0 // indirect
github.com/felixge/httpsnoop v1.0.3 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-openapi/jsonpointer v0.19.5 // indirect
github.com/go-openapi/jsonreference v0.20.0 // indirect
github.com/go-openapi/swag v0.19.14 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
github.com/go-openapi/jsonreference v0.20.1 // indirect
github.com/go-openapi/swag v0.22.3 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/protobuf v1.5.2 // indirect
github.com/google/cel-go v0.12.5 // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/google/cel-go v0.12.6 // indirect
github.com/google/gnostic v0.5.7-v3refs // indirect
github.com/google/go-cmp v0.5.9 // indirect
github.com/google/gofuzz v1.1.0 // indirect
github.com/google/uuid v1.1.2 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.7.0 // indirect
github.com/imdario/mergo v0.3.12 // indirect
github.com/inconshreveable/mousetrap v1.0.1 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/mailru/easyjson v0.7.6 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.2 // indirect
github.com/mitchellh/mapstructure v1.4.1 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
Expand All @@ -68,12 +70,12 @@ require (
github.com/spf13/cobra v1.6.0 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/stoewer/go-strcase v1.2.0 // indirect
github.com/stretchr/objx v0.4.0 // indirect
go.etcd.io/etcd/api/v3 v3.5.5 // indirect
go.etcd.io/etcd/client/pkg/v3 v3.5.5 // indirect
go.etcd.io/etcd/client/v3 v3.5.5 // indirect
github.com/stretchr/objx v0.5.0 // indirect
go.etcd.io/etcd/api/v3 v3.5.7 // indirect
go.etcd.io/etcd/client/pkg/v3 v3.5.7 // indirect
go.etcd.io/etcd/client/v3 v3.5.7 // indirect
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.35.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.35.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.35.1 // indirect
go.opentelemetry.io/otel v1.10.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/internal/retry v1.10.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.10.0 // indirect
Expand All @@ -85,24 +87,25 @@ require (
go.uber.org/atomic v1.7.0 // indirect
go.uber.org/multierr v1.6.0 // indirect
go.uber.org/zap v1.24.0 // indirect
golang.org/x/mod v0.6.0 // indirect
golang.org/x/net v0.3.1-0.20221206200815-1e63c2f08a10 // indirect
golang.org/x/crypto v0.1.0 // indirect
golang.org/x/mod v0.9.0 // indirect
golang.org/x/net v0.8.0 // indirect
golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b // indirect
golang.org/x/sys v0.3.0 // indirect
golang.org/x/term v0.3.0 // indirect
golang.org/x/text v0.5.0 // indirect
golang.org/x/sys v0.6.0 // indirect
golang.org/x/term v0.6.0 // indirect
golang.org/x/text v0.8.0 // indirect
golang.org/x/time v0.3.0 // indirect
golang.org/x/tools v0.2.0 // indirect
golang.org/x/tools v0.7.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20220502173005-c8bf987b8c21 // indirect
google.golang.org/grpc v1.49.0 // indirect
google.golang.org/grpc v1.51.0 // indirect
google.golang.org/protobuf v1.28.1 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/kube-openapi v0.0.0-20221012153701-172d655c2280 // indirect
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.33 // indirect
sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2 // indirect
k8s.io/kube-openapi v0.0.0-20230501164219-8b0f38b5fd1f // indirect
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.1.2 // indirect
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect
sigs.k8s.io/yaml v1.3.0 // indirect
)
Loading

0 comments on commit 6005d29

Please sign in to comment.