Bumping k8s version to 1.13.0-beta.1
This commit is contained in:
16
vendor/k8s.io/client-go/examples/workqueue/main.go
generated
vendored
16
vendor/k8s.io/client-go/examples/workqueue/main.go
generated
vendored
@@ -21,7 +21,7 @@ import (
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/golang/glog"
|
||||
"k8s.io/klog"
|
||||
|
||||
"k8s.io/api/core/v1"
|
||||
meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
@@ -72,7 +72,7 @@ func (c *Controller) processNextItem() bool {
|
||||
func (c *Controller) syncToStdout(key string) error {
|
||||
obj, exists, err := c.indexer.GetByKey(key)
|
||||
if err != nil {
|
||||
glog.Errorf("Fetching object with key %s from store failed with %v", key, err)
|
||||
klog.Errorf("Fetching object with key %s from store failed with %v", key, err)
|
||||
return err
|
||||
}
|
||||
|
||||
@@ -99,7 +99,7 @@ func (c *Controller) handleErr(err error, key interface{}) {
|
||||
|
||||
// This controller retries 5 times if something goes wrong. After that, it stops trying.
|
||||
if c.queue.NumRequeues(key) < 5 {
|
||||
glog.Infof("Error syncing pod %v: %v", key, err)
|
||||
klog.Infof("Error syncing pod %v: %v", key, err)
|
||||
|
||||
// Re-enqueue the key rate limited. Based on the rate limiter on the
|
||||
// queue and the re-enqueue history, the key will be processed later again.
|
||||
@@ -110,7 +110,7 @@ func (c *Controller) handleErr(err error, key interface{}) {
|
||||
c.queue.Forget(key)
|
||||
// Report to an external entity that, even after several retries, we could not successfully process this key
|
||||
runtime.HandleError(err)
|
||||
glog.Infof("Dropping pod %q out of the queue: %v", key, err)
|
||||
klog.Infof("Dropping pod %q out of the queue: %v", key, err)
|
||||
}
|
||||
|
||||
func (c *Controller) Run(threadiness int, stopCh chan struct{}) {
|
||||
@@ -118,7 +118,7 @@ func (c *Controller) Run(threadiness int, stopCh chan struct{}) {
|
||||
|
||||
// Let the workers stop when we are done
|
||||
defer c.queue.ShutDown()
|
||||
glog.Info("Starting Pod controller")
|
||||
klog.Info("Starting Pod controller")
|
||||
|
||||
go c.informer.Run(stopCh)
|
||||
|
||||
@@ -133,7 +133,7 @@ func (c *Controller) Run(threadiness int, stopCh chan struct{}) {
|
||||
}
|
||||
|
||||
<-stopCh
|
||||
glog.Info("Stopping Pod controller")
|
||||
klog.Info("Stopping Pod controller")
|
||||
}
|
||||
|
||||
func (c *Controller) runWorker() {
|
||||
@@ -152,13 +152,13 @@ func main() {
|
||||
// creates the connection
|
||||
config, err := clientcmd.BuildConfigFromFlags(master, kubeconfig)
|
||||
if err != nil {
|
||||
glog.Fatal(err)
|
||||
klog.Fatal(err)
|
||||
}
|
||||
|
||||
// creates the clientset
|
||||
clientset, err := kubernetes.NewForConfig(config)
|
||||
if err != nil {
|
||||
glog.Fatal(err)
|
||||
klog.Fatal(err)
|
||||
}
|
||||
|
||||
// create the pod watcher
|
||||
|
Reference in New Issue
Block a user