Commit Graph

91 Commits (1ed12001436fbe86c2aa20505e31c58738398e7c)

Author SHA1 Message Date
xiangpengzhao 8719b4a8ea Remove deprecated init-container in annotations 2017-08-25 13:39:29 +08:00
Kubernetes Submit Queue 5bb42cbc58 Merge pull request #47828 from yiqinguo/yiqinguo_add_continue
Automatic merge from submit-queue

If error continue for loop

If err does not add continue, type conversion will be error.
If do not add continue, pod. (* V1.Pod) may cause panic to run.
**Release note**:
```release-note
NONE
```
2017-08-01 21:41:43 -07:00
yiqinguo 96c0fe9b11 If err does not add continue, type conversion will be error.
If do not add continue, pod. (* V1.Pod) may cause panic to run.
2017-08-01 09:30:02 +08:00
Chao Xu f4989a45a5 run root-rewrite-v1-..., compile 2017-06-22 10:25:57 -07:00
Random-Liu fbc320af28 Use uid in config.go instead of pod full name. 2017-03-20 15:52:29 -07:00
deads2k 8a12000402 move client/record 2017-01-31 19:14:13 -05:00
deads2k 6a4d5cd7cc start the apimachinery repo 2017-01-11 09:09:48 -05:00
Chao Xu 8554d8e0db fix concurrent read/write to map error caused by SetInitContainersAndStatuses in kubelet 2016-11-28 11:56:21 -08:00
Chao Xu bcc783c594 run hack/update-all.sh 2016-11-23 15:53:09 -08:00
Chao Xu 5e1adf91df cmd/kubelet 2016-11-23 15:53:09 -08:00
Ke Zhang 29edf62778 change sourcesSeenLock to sync.RWMutex 2016-08-31 09:10:14 +08:00
Ke Zhang e143c38310 make the removing pods log standardized 2016-08-01 18:41:40 +08:00
Ron Lai e6b745122d Moving event.go from kubelet/container to kubelet/events 2016-07-12 17:42:29 -07:00
k8s-merge-robot 72f6493376 Merge pull request #27349 from resouer/delete
Automatic merge from submit-queue

Generates DELETE pod update operations

fixes #27105

Generates DELETE pod update operations  to make the code and log more intuitive.

1. main refactoring is in `kubelet/config`
2. kubelet will log if it received DELETE, just like other OPs

cc @Random-Liu :)
2016-07-12 01:04:35 -07:00
Harry Zhang 0d5dddcb71 Add DELETE event type
Signed-off-by: Harry Zhang <harryz@hyper.sh>

Combine delete with update
2016-07-12 14:08:01 +08:00
David McMahon ef0c9f0c5b Remove "All rights reserved" from all the headers. 2016-06-29 17:47:36 -07:00
Yu-Ju Hong deafa44d61 kubelet: send all recevied pods in one update
The kubelet sync loop relies on getting one update as the signal that the
specific source is ready. This change ensures that we don't send multiple
updates (ADD, UPDATE) for the first batch of pods. This is required to prevent
the cleanup routine from killing pods prematurely.
2016-03-17 14:24:35 -07:00
k8s-merge-robot 7e158006c0 Merge pull request #19940 from yujuhong/fix_update
Auto commit by PR queue bot
2016-02-01 13:35:54 -08:00
Random-Liu 488e14a5a9 Cleanup duplicated code in config.go 2016-01-28 01:04:35 -08:00
Yu-Ju Hong 0fada52788 Fix sending an empty update when the source is ready 2016-01-21 14:24:39 -08:00
k8s-merge-robot 67ac4e3838 Merge pull request #18410 from Random-Liu/reconcile-pod-status
Auto commit by PR queue bot
2016-01-12 02:17:09 -08:00
Random-Liu 5b4a210d49 Add reconcile support in kubelet 2016-01-10 01:35:07 -08:00
Yu-Ju Hong 712612c2dc Treat first-seen, non-pending pods as updates
Kubelet doesn't perform checkpointing and loses all its internal states after
restarts. It'd then mistaken pods from the api server as new pods and attempt
to go through the admission process. This may result in pods being rejected
even though they are running on the node (e.g., out of disk situation). This
change adds a condition to check whether the pod was seen before and categorize
such pods as updates. The change also removes freeze/unfreeze mechanism used to
work around such cases, since it is no longer needed and it stopped working
correctly ever since we switched to incremental updates.
2016-01-08 17:21:43 -08:00
k8s-merge-robot c2189fd60d Merge pull request #18518 from Random-Liu/fix-potential-data-race
Auto commit by PR queue bot
2015-12-16 09:45:52 -08:00
Tim Hockin 7fb8f60735 Shorten names for better reading 2015-12-10 11:48:19 -08:00
Tim Hockin 87a35047dd Move FieldPath and errors to a sub-package
This makes the naming and reading a lot simpler.
2015-12-10 11:48:16 -08:00
Random-Liu eb551f388c Fix potential data race 2015-12-10 10:35:02 -08:00
k8s-merge-robot 37d22999b4 Merge pull request #17572 from yujuhong/kubeutil
Auto commit by PR queue bot
2015-12-04 03:15:54 -08:00
Yu-Ju Hong a4816b3bcb Make kublet/util/format.go a separate package
The formatting function is used often in logging. This improves the readability
by shortening the length of the call. Also change the fomartted string to
include the pod UID.
2015-12-03 12:47:36 -08:00
Tim Hockin e6df0b1a24 Convert validation to use FieldPath
Before this change we have a mish-mash of ways to pass field names around for
error generation.  Sometimes string fieldnames, sometimes .Prefix(), sometimes
neither, often wrong names or not indexed when it should be.

Instead of that mess, this is part one of a couple of commits that will make it
more strongly typed and hopefully encourage correct behavior.  At least you
will have to think about field names, which is better than nothing.

It turned out to be really hard to do this incrementally.
2015-12-03 08:19:44 -08:00
k8s-merge-robot 431c67710b Merge pull request #17247 from thockin/airplane_validation_pt3
Auto commit by PR queue bot
2015-11-24 18:37:09 -08:00
Avesh Agarwal 3d5207fd73 This commit adds type information to events.
This addresses issue #15624.
2015-11-24 09:59:54 -05:00
Tim Hockin ceee678b29 Rename validation 'New' funcs 2015-11-23 10:01:43 -08:00
Tim Hockin 682f2a5a79 Stronger typing for validation ErrorList 2015-11-23 10:01:43 -08:00
Tim Hockin 0ff66da346 Move fielderrors into validation 2015-11-22 20:12:20 -08:00
jiangyaoguo b0f0c294d9 make reasons constants with clarity 2015-11-09 23:42:14 +08:00
k8s-merge-robot 4736adee8f Merge pull request #15621 from mesosphere/sttts-send-initial-set-to-get-seen
Auto commit by PR queue bot
2015-10-16 08:04:29 -07:00
eulerzgy ea86e66fbe Del capatical local packagename for kubeletUtil 2015-10-15 09:58:10 +08:00
Dr. Stefan Schimanski 7dddec6799 Switch to empty ADD PodUpdate for PodConfigNotificationIncremental mode 2015-10-14 15:38:44 +02:00
Dr. Stefan Schimanski 5cfeb53057 Enforce an initial empty SET PodConfig
In PodConfigNotificationIncremental PodConfig mode, when no pods are available
for a source, the Merge function correctly concluded that neither ADD, UPDATE nor
REMOVE updates are to be sent to the kubelet. But as a consequence the kubelet will
not mark that source as seen.

This is usually not a problem for the apiserver source. But it is a problem for
an empty "file" source, e.g. by passing an empty directory to the kubelet for
static pods. Then the file source will never be seen and the kubelet will stay
in its special not-all-source-seen mode.
2015-10-14 14:22:44 +02:00
Yu-Ju Hong a3e60cc32e Rename imported package local name kubeletTypes to kubetypes
According to the naming guidelines, package name should not include mixedCaps.
2015-10-09 10:24:31 -07:00
k8s-merge-robot 45cca144cb Merge pull request #15167 from yujuhong/sources_seen
Auto commit by PR queue bot
2015-10-09 08:35:40 -07:00
Yu-Ju Hong 098ab05997 kubelet: move common types to kubelet/types
This would faciliate tasks such as moving code in pkg/kubelet to sub packages.
2015-10-08 14:38:01 -07:00
Yu-Ju Hong 5abdfcdfe6 kubelet: fix all sources ready condition
The current implementation considers a source seen when it receives a SET at
kubelet/config/config.go. However, the main kubelet sync loop may not have
received the pod update from the source via the channel. This change ensures
that kubelet would consider all sources are ready only after the sync loop has
seen all the sources.
2015-10-06 10:13:04 -07:00
Salvatore Dario Minonne 32f56619a7 Partial fix for issue #14263 2015-09-25 15:29:00 +02:00
Nikhil Jindal 9e5ed1dc69 Merge pull request #13880 from yujuhong/fix_annotations
Fix source annotation in kubelet
2015-09-17 23:28:41 -07:00
Yu-Ju Hong fb270779b5 kubelet: fix the config unit tests 2015-09-14 11:07:27 -07:00
Tamer Tas 6908790410 Add a default value to PodConfigNotificationMode 2015-09-14 15:00:01 +03:00
Yu-Ju Hong 69c3aa0872 Fix source annotation in kubelet
kubelet relies on source annotation to distinguish pods from different sources.
It should always annotate the source when receiving the pod to avoid any
confusion. This commit fixes that and also make sure we don't overwrite the
first seen time.
2015-09-11 14:52:16 -07:00
Daniel Smith 15b30b8b09 Move version agnostic parts of client
pkg/client/unversioned/cache -> pkg/client/cache
pkg/client/unversioned/record -> pkg/client/record
2015-09-10 17:17:59 -07:00