Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
4 changes: 2 additions & 2 deletions Gopkg.lock

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

4 changes: 2 additions & 2 deletions Gopkg.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ required = [

[[constraint]]
name = "github.com/knative/pkg"
# HEAD as of 2018-09-06
revision = "0122abd98318e345b107e01137ff05c33aa637d2"
# HEAD as of 2018-09-12
revision = "8fc80deb200e7853795e6baf4029f406ca9534b8"

[[constraint]]
name = "github.com/knative/caching"
Expand Down
2 changes: 1 addition & 1 deletion cmd/activator/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ func main() {
}()

// Watch the logging config map and dynamically update logging levels.
configMapWatcher := configmap.NewDefaultWatcher(kubeClient, system.Namespace)
configMapWatcher := configmap.NewInformedWatcher(kubeClient, system.Namespace)
configMapWatcher.Watch(logging.ConfigName, logging.UpdateLevelFromConfigMap(logger, atomicLevel, logLevelKey))
if err = configMapWatcher.Start(stopCh); err != nil {
logger.Fatalf("failed to start configuration manager: %v", err)
Expand Down
2 changes: 1 addition & 1 deletion cmd/autoscaler/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ func main() {
}

// Watch the logging config map and dynamically update logging levels.
configMapWatcher := configmap.NewDefaultWatcher(kubeClientSet, system.Namespace)
configMapWatcher := configmap.NewInformedWatcher(kubeClientSet, system.Namespace)
configMapWatcher.Watch(logging.ConfigName, logging.UpdateLevelFromConfigMap(logger, atomicLevel, logLevelKey))

// This is based on how Kubernetes sets up its scale client based on discovery:
Expand Down
2 changes: 1 addition & 1 deletion cmd/controller/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ func main() {
time.Minute*5, system.Namespace, nil)
vpaInformerFactory := vpainformers.NewSharedInformerFactory(vpaClient, time.Second*30)

configMapWatcher := configmap.NewDefaultWatcher(kubeClient, system.Namespace)
configMapWatcher := configmap.NewInformedWatcher(kubeClient, system.Namespace)

opt := reconciler.Options{
KubeClientSet: kubeClient,
Expand Down
2 changes: 1 addition & 1 deletion cmd/webhook/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ func main() {
}

// Watch the logging config map and dynamically update logging levels.
configMapWatcher := configmap.NewDefaultWatcher(kubeClient, system.Namespace)
configMapWatcher := configmap.NewInformedWatcher(kubeClient, system.Namespace)
configMapWatcher.Watch(logging.ConfigName, logging.UpdateLevelFromConfigMap(logger, atomicLevel, logLevelKey))
if err = configMapWatcher.Start(stopCh); err != nil {
logger.Fatalf("failed to start configuration manager: %v", err)
Expand Down
2 changes: 1 addition & 1 deletion pkg/reconciler/v1alpha1/autoscaling/autoscaling_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ var (
)

func newConfigWatcher() configmap.Watcher {
return configmap.NewFixedWatcher(
return configmap.NewStaticWatcher(
&corev1.ConfigMap{
ObjectMeta: metav1.ObjectMeta{
Namespace: system.Namespace,
Expand Down
2 changes: 1 addition & 1 deletion pkg/reconciler/v1alpha1/revision/queueing_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ func newTestController(t *testing.T, servingObjects ...runtime.Object) (
servingClient = fakeclientset.NewSimpleClientset(servingObjects...)
vpaClient = fakevpaclientset.NewSimpleClientset()

configMapWatcher = configmap.NewFixedWatcher(&corev1.ConfigMap{
configMapWatcher = configmap.NewStaticWatcher(&corev1.ConfigMap{
ObjectMeta: metav1.ObjectMeta{
Namespace: system.Namespace,
Name: config.NetworkConfigName,
Expand Down
2 changes: 1 addition & 1 deletion pkg/reconciler/v1alpha1/revision/revision_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ func newTestControllerWithConfig(t *testing.T, controllerConfig *config.Controll
cms = append(cms, cm)
}

configMapWatcher = configmap.NewFixedWatcher(cms...)
configMapWatcher = configmap.NewStaticWatcher(cms...)

// Create informer factories with fake clients. The second parameter sets the
// resync period to zero, disabling it.
Expand Down
2 changes: 1 addition & 1 deletion pkg/reconciler/v1alpha1/route/queueing_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func TestNewRouteCallsSyncHandler(t *testing.T) {

// Create fake clients
kubeClient := fakekubeclientset.NewSimpleClientset()
configMapWatcher := configmap.NewFixedWatcher(&corev1.ConfigMap{
configMapWatcher := configmap.NewStaticWatcher(&corev1.ConfigMap{
ObjectMeta: metav1.ObjectMeta{
Name: config.DomainConfigName,
Namespace: system.Namespace,
Expand Down
2 changes: 1 addition & 1 deletion pkg/reconciler/v1alpha1/route/route_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ func newTestSetup(t *testing.T, configs ...*corev1.ConfigMap) (
cms = append(cms, cm)
}

configMapWatcher = configmap.NewFixedWatcher(cms...)
configMapWatcher = configmap.NewStaticWatcher(cms...)
sharedClient = fakesharedclientset.NewSimpleClientset()
servingClient = fakeclientset.NewSimpleClientset()

Expand Down
128 changes: 0 additions & 128 deletions vendor/github.com/knative/pkg/configmap/default.go

This file was deleted.

122 changes: 122 additions & 0 deletions vendor/github.com/knative/pkg/configmap/informed_watcher.go

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

Loading