Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
626ff900
Commit
626ff900
authored
May 16, 2016
by
Wojciech Tyczynski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Explicitly enqueue controllers on failures and increase resync period
parent
aada051b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletion
+7
-1
replication_controller.go
pkg/controller/replication/replication_controller.go
+7
-1
No files found.
pkg/controller/replication/replication_controller.go
View file @
626ff900
...
@@ -47,7 +47,11 @@ const (
...
@@ -47,7 +47,11 @@ const (
// We'll attempt to recompute the required replicas of all replication controllers
// We'll attempt to recompute the required replicas of all replication controllers
// that have fulfilled their expectations at least this often. This recomputation
// that have fulfilled their expectations at least this often. This recomputation
// happens based on contents in local pod storage.
// happens based on contents in local pod storage.
FullControllerResyncPeriod
=
30
*
time
.
Second
// Full Resync shouldn't be needed at all in a healthy system. This is a protection
// against disappearing objects and watch notification, that we believe should not
// happen at all.
// TODO: We should get rid of it completely in the fullness of time.
FullControllerResyncPeriod
=
10
*
time
.
Minute
// Realistic value of the burstReplica field for the replication manager based off
// Realistic value of the burstReplica field for the replication manager based off
// performance requirements for kubernetes 1.0.
// performance requirements for kubernetes 1.0.
...
@@ -477,6 +481,7 @@ func (rm *ReplicationManager) manageReplicas(filteredPods []*api.Pod, rc *api.Re
...
@@ -477,6 +481,7 @@ func (rm *ReplicationManager) manageReplicas(filteredPods []*api.Pod, rc *api.Re
// Decrement the expected number of creates because the informer won't observe this pod
// Decrement the expected number of creates because the informer won't observe this pod
glog
.
V
(
2
)
.
Infof
(
"Failed creation, decrementing expectations for controller %q/%q"
,
rc
.
Namespace
,
rc
.
Name
)
glog
.
V
(
2
)
.
Infof
(
"Failed creation, decrementing expectations for controller %q/%q"
,
rc
.
Namespace
,
rc
.
Name
)
rm
.
expectations
.
CreationObserved
(
rcKey
)
rm
.
expectations
.
CreationObserved
(
rcKey
)
rm
.
enqueueController
(
rc
)
utilruntime
.
HandleError
(
err
)
utilruntime
.
HandleError
(
err
)
}
}
}()
}()
...
@@ -518,6 +523,7 @@ func (rm *ReplicationManager) manageReplicas(filteredPods []*api.Pod, rc *api.Re
...
@@ -518,6 +523,7 @@ func (rm *ReplicationManager) manageReplicas(filteredPods []*api.Pod, rc *api.Re
podKey
:=
controller
.
PodKey
(
filteredPods
[
ix
])
podKey
:=
controller
.
PodKey
(
filteredPods
[
ix
])
glog
.
V
(
2
)
.
Infof
(
"Failed to delete %v due to %v, decrementing expectations for controller %q/%q"
,
podKey
,
err
,
rc
.
Namespace
,
rc
.
Name
)
glog
.
V
(
2
)
.
Infof
(
"Failed to delete %v due to %v, decrementing expectations for controller %q/%q"
,
podKey
,
err
,
rc
.
Namespace
,
rc
.
Name
)
rm
.
expectations
.
DeletionObserved
(
rcKey
,
podKey
)
rm
.
expectations
.
DeletionObserved
(
rcKey
,
podKey
)
rm
.
enqueueController
(
rc
)
utilruntime
.
HandleError
(
err
)
utilruntime
.
HandleError
(
err
)
}
}
}(
i
)
}(
i
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment