Commit Graph

30 Commits

Author SHA1 Message Date
Matthew Cary
53b3a6c1d9 controller change for statefulset auto-delete (tests)
Change-Id: I16b50e6853bba65fc89c793d2b9b335581c02407
2021-11-17 16:48:50 -08:00
Mike Dame
41fcb95f2f Wire contexts to Apps controllers 2021-10-13 16:32:13 -04:00
wawa0210
d360be0f7c
fix pkg/controller/statefulset staticcheck 2020-06-26 00:00:41 +08:00
taesun_lee
79680b5d9b Fix pkg/controller typos in some error messages, comments etc
- applied review results by LuisSanchez
- Co-Authored-By: Luis Sanchez <sanchezl@redhat.com>

genernal -> general
iniital -> initial
initalObjects -> initialObjects
intentionaly -> intentionally
inforer -> informer
anotother -> another
triger -> trigger
mutli -> multi
Verifyies -> Verifies
valume -> volume
unexpect -> unexpected
unfulfiled -> unfulfilled
implenets -> implements
assignement -> assignment
expectataions -> expectations
nexpected -> unexpected
boundSatsified -> boundSatisfied
externel -> external
calcuates -> calculates
workes -> workers
unitialized -> uninitialized
afater -> after
Espected -> Expected
nodeMontiorGracePeriod -> NodeMonitorGracePeriod
estimateGrracefulTermination -> estimateGracefulTermination
secondrary -> secondary
ShouldRunDaemonPodOnUnscheduableNode -> ShouldRunDaemonPodOnUnschedulableNode
rrror -> error
expectatitons -> expectations
foud -> found
epackage -> package
succesfulJobs -> successfulJobs
namesapce -> namespace
ConfigMapResynce -> ConfigMapResync
2020-02-27 00:15:33 +09:00
Yecheng Fu
bb2b50f3db Garbage collector should orphan ControllerRevisions too
Signed-off-by: Yecheng Fu <fuyecheng@pingcap.com>
2020-02-10 20:58:28 +08:00
likakuli
10864d3366 fix a bug that orphan revision cannot be adopted and sts cannot be synced 2020-01-08 17:56:41 +08:00
Humble Chirammal
48e1838f6c Remove unwanted else block from statefulset controller.
Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
2019-04-01 16:24:55 +05:30
Minhan Xia
cb9ac04777 fix unit tests using Patch in fake client 2018-05-30 11:33:55 -07:00
dhilipkumars
aba725a391 Promote SS to apps/v1 2018-01-18 13:48:52 +05:30
Tomas Nozicka
f6af1904cd Make StatefulSet report an event when recreating failed pod 2017-11-09 12:23:37 +01:00
Lars Lehtonen
9f8d57a2d4
Fix swallowed errors in statefulset tests 2017-08-21 17:12:36 -07:00
Kubernetes Submit Queue
f0066597ca Merge pull request #50220 from zhangxiaoyu-zidif/delete-statefulset-test-redundant-sort
Automatic merge from submit-queue (batch tested with PRs 50536, 50809, 50220, 50399, 50176)

Refactor statefulset test with sets.String

**What this PR does / why we need it**:
Delete redundant sort. These string slices only own one element.
There is no necessary to sort them.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-08-17 18:12:06 -07:00
zhangxiaoyu-zidif
3393cf4718 fix-review 2017-08-17 06:00:02 +08:00
zhangxiaoyu-zidif
db2e7cd69a fix-review 2017-08-12 13:31:08 +08:00
Jacob Simpson
29c1b81d4c Scripted migration from clientset_generated to client-go. 2017-07-17 15:05:37 -07:00
Chao Xu
60604f8818 run hack/update-all 2017-06-22 11:31:03 -07:00
Chao Xu
cde4772928 run ./root-rewrite-all-other-apis.sh, then run make all, pkg/... compiles 2017-06-22 11:30:52 -07:00
Chao Xu
f4989a45a5 run root-rewrite-v1-..., compile 2017-06-22 10:25:57 -07:00
Kenneth Owens
1b55f57391 Implements StatefulSet update
Implements history utilities for ControllerRevision in the controller/history package
StatefulSetStatus now has additional fields for consistency with DaemonSet and Deployment
StatefulSetStatus.Replicas now represents the current number of createdPods and StatefulSetStatus.ReadyReplicas is the current number of ready Pods
2017-06-06 12:00:28 -07:00
Clayton Coleman
20d45af694
Combine statefulset burst and monotonic scaling tests
Use subtests to avoid duplicating entire suite of control logic.
2017-05-21 01:14:30 -04:00
Kenneth Owens
7d22e64284 StatefulSet should not launch Pod i, if a Pod in the sequence [0,i) has its
DeletionTimestamp set. Fixes 44229.
Rename isTerminated to isTerminating
Adds a test case for at the unit level to prevent regression
2017-04-21 08:38:21 -07:00
Anthony Yeh
b4b8fdbca3 GC: Fix re-adoption race when orphaning dependents.
The GC expects that once it sees a controller with a non-nil
DeletionTimestamp, that controller will not attempt any adoption.
There was a known race condition that could cause a controller to
re-adopt something orphaned by the GC, because the controller is using a
cached value of its own spec from before DeletionTimestamp was set.

This fixes that race by doing an uncached quorum read of the controller
spec just before the first adoption attempt. It's important that this
read occurs after listing potential orphans. Note that this uncached
read is skipped if no adoptions are attempted (i.e. at steady state).
2017-03-17 15:39:26 -07:00
Anthony Yeh
ea85a201c7 StatefulSet: Use ControllerRef to route watch events.
This is part of the completion of ControllerRef, as described here:

https://github.com/kubernetes/community/blob/master/contributors/design-proposals/controller-ref.md#watches
2017-03-06 09:46:03 -08:00
Anthony Yeh
e4f67c8170 StatefulSet: Use ControllerRefManager to adopt/orphan. 2017-03-06 09:46:03 -08:00
Andy Goldstein
bd912f50ba statefulset: use pvc lister, replace legacylisters
Use a PVC lister instead of a client when retrieving PVCs.

Replace unit test's use of legacylisters with the generated listers.
2017-02-27 06:38:11 -05:00
Andy Goldstein
f6a186b1e1 Switch statefulset controller to shared informers 2017-02-22 08:53:51 -05:00
Kenneth Owens
4d99b4d825 StatefulSet refactoring and semantics fix
1. pcb and pcb controller are removed and their functionality is
encapsulated in StatefulPodControlInterface.
2. IdentityMappers has been removed to clarify what properties of a Pod are
mutated by the controller. All mutations are performed in the
UpdateStatefulPod method of the StatefulPodControlInterface.
3. The statefulSetIterator and petQueue classes are removed. These classes
sorted Pods by CreationTimestamp. This is brittle and not resilient to
clock skew. The current control loop, which implements the same logic,
is in stateful_set_control.go. The Pods are now sorted and considered by
their ordinal indices, as is outlined in the documentation.
4. StatefulSetController now checks to see if the Pods matching a
StatefulSet's Selector also match the Name of the StatefulSet. This will
make the controller resilient to overlapping, and will be enhanced by
the addition of ControllerRefs.
2017-02-09 08:42:28 -08:00
deads2k
b0b156b381 make tools/cache authoritative 2017-01-25 08:29:45 -05:00
deads2k
1ce0637b27 move listers out of cache to reduce import tree 2017-01-20 15:01:38 -05:00
Harry Zhang
b8678ad130 Use statefulset instead in controller
Rename e2e folder to statefulset
2017-01-17 10:36:37 +08:00