Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

✨ Update to Kubernetes 1.12.2 #221

Merged
merged 2 commits into from
Dec 1, 2018
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions pkg/client/unstructured_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func (uc *unstructuredClient) Create(_ context.Context, obj runtime.Object) erro
if err != nil {
return err
}
i, err := r.Create(u)
i, err := r.Create(u, metav1.CreateOptions{})
if err != nil {
return err
}
Expand All @@ -64,7 +64,7 @@ func (uc *unstructuredClient) Update(_ context.Context, obj runtime.Object) erro
if err != nil {
return err
}
i, err := r.Update(u)
i, err := r.Update(u, metav1.UpdateOptions{})
if err != nil {
return err
}
Expand Down Expand Up @@ -142,7 +142,7 @@ func (uc *unstructuredClient) UpdateStatus(_ context.Context, obj runtime.Object
if err != nil {
return err
}
i, err := r.UpdateStatus(u)
i, err := r.UpdateStatus(u, metav1.UpdateOptions{})
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@droot we'll want to surface create options somewhere in our client at some point

if err != nil {
return err
}
Expand Down
4 changes: 2 additions & 2 deletions pkg/manager/internal.go
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ func (cm *controllerManager) startLeaderElection() (err error) {
RenewDeadline: 10 * time.Second,
RetryPeriod: 2 * time.Second,
Callbacks: leaderelection.LeaderCallbacks{
OnStartedLeading: func(_ <-chan struct{}) {
OnStartedLeading: func(_ context.Context) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we'll want to surface this too

cm.start()
},
OnStoppedLeading: func() {
Expand All @@ -284,6 +284,6 @@ func (cm *controllerManager) startLeaderElection() (err error) {
}

// Start the leader elector process
go l.Run()
go l.Run(context.Background())
return nil
}
4 changes: 2 additions & 2 deletions pkg/runtime/scheme/scheme_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ var _ = Describe("Scheme", func() {
Build()
Expect(err).NotTo(HaveOccurred())

Expect(s.AllKnownTypes()).To(HaveLen(13))
Expect(s.AllKnownTypes()).To(HaveLen(15))
Expect(s.AllKnownTypes()[gv.WithKind("Pod")]).To(Equal(reflect.TypeOf(corev1.Pod{})))
Expect(s.AllKnownTypes()[gv.WithKind("PodList")]).To(Equal(reflect.TypeOf(corev1.PodList{})))

Expand Down Expand Up @@ -71,7 +71,7 @@ var _ = Describe("Scheme", func() {
Build()

Expect(err).NotTo(HaveOccurred())
Expect(s.AllKnownTypes()).To(HaveLen(21))
Expect(s.AllKnownTypes()).To(HaveLen(25))

// Types from b1
Expect(s.AllKnownTypes()[gv1.WithKind("Pod")]).To(Equal(reflect.TypeOf(corev1.Pod{})))
Expand Down