Skip to content

Commit

Permalink
Update k8s libraries to 1.12.3 (#1054)
Browse files Browse the repository at this point in the history
* Update k8s libraries to 1.12.3

* Update v1beta2 code

* Remove go 1.9 support in travisw
  • Loading branch information
johnugeorge authored and k8s-ci-robot committed Aug 2, 2019
1 parent 7ccfeaf commit c47c5ca
Show file tree
Hide file tree
Showing 510 changed files with 58,477 additions and 36,777 deletions.
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
language: go

go:
- "1.9"
- "1.10"

go_import_path: github.com/kubeflow/tf-operator
Expand Down
67 changes: 45 additions & 22 deletions Gopkg.lock

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

16 changes: 6 additions & 10 deletions Gopkg.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ required = [

[[constraint]]
name = "k8s.io/client-go"
version = "kubernetes-1.11.2"
version = "kubernetes-1.12.3"

[[constraint]]
# kube-openapi does not have any version.
Expand All @@ -40,23 +40,19 @@ required = [

[[constraint]]
name = "k8s.io/kubernetes"
version = "v1.11.2"
version = "v1.12.3"

[[constraint]]
name = "k8s.io/api"
version = "kubernetes-1.11.2"
version = "kubernetes-1.12.3"

[[constraint]]
name = "k8s.io/apimachinery"
version = "kubernetes-1.11.2"

[[constraint]]
name = "k8s.io/apiextensions-apiserver"
version = "kubernetes-1.11.2"
version = "kubernetes-1.12.3"

[[constraint]]
name = "k8s.io/code-generator"
version = "kubernetes-1.11.2"
version = "kubernetes-1.12.3"

[[constraint]]
name = "github.com/prometheus/client_golang"
Expand Down Expand Up @@ -85,7 +81,7 @@ required = [

[[override]]
name = "k8s.io/apiserver"
version = "kubernetes-1.11.2"
version = "kubernetes-1.12.3"

[prune]
go-tests = true
Expand Down
5 changes: 3 additions & 2 deletions cmd/tf-operator.v1/app/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
package app

import (
"context"
"fmt"
"os"
"time"
Expand Down Expand Up @@ -127,7 +128,7 @@ func Run(opt *options.ServerOption) error {
go unstructuredInformer.Informer().Run(stopCh)

// Set leader election start function.
run := func(<-chan struct{}) {
run := func(context.Context) {
isLeader.Set(1)
if err := tc.Run(opt.Threadiness, stopCh); err != nil {
log.Errorf("Failed to run the controller: %v", err)
Expand Down Expand Up @@ -161,7 +162,7 @@ func Run(opt *options.ServerOption) error {
}

// Start leader election.
election.RunOrDie(election.LeaderElectionConfig{
election.RunOrDie(context.TODO(), election.LeaderElectionConfig{
Lock: rl,
LeaseDuration: leaseDuration,
RenewDeadline: renewDuration,
Expand Down
5 changes: 3 additions & 2 deletions cmd/tf-operator.v1beta2/app/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
package app

import (
"context"
"fmt"
"os"
"time"
Expand Down Expand Up @@ -118,7 +119,7 @@ func Run(opt *options.ServerOption) error {
go unstructuredInformer.Informer().Run(stopCh)

// Set leader election start function.
run := func(<-chan struct{}) {
run := func(context.Context) {
if err := tc.Run(opt.Threadiness, stopCh); err != nil {
log.Errorf("Failed to run the controller: %v", err)
}
Expand Down Expand Up @@ -149,7 +150,7 @@ func Run(opt *options.ServerOption) error {
}

// Start leader election.
election.RunOrDie(election.LeaderElectionConfig{
election.RunOrDie(context.TODO(), election.LeaderElectionConfig{
Lock: rl,
LeaseDuration: leaseDuration,
RenewDeadline: renewDuration,
Expand Down
Loading

0 comments on commit c47c5ca

Please sign in to comment.