Commit Graph

244 Commits (05eb75612fc14a1ef017b044f40470ff45e9f550)

Author SHA1 Message Date
deads2k 6a4d5cd7cc start the apimachinery repo 2017-01-11 09:09:48 -05:00
Jeff Grafton 20d221f75c Enable auto-generating sources rules 2017-01-05 14:14:13 -08:00
Dr. Stefan Schimanski 87dd990bb7 Move pkg/api.{Context,RequestContextMapper} into pkg/genericapiserver/api/request 2017-01-03 14:57:33 +01:00
Dr. Stefan Schimanski 2d58ffc129 Move pkg/{apiserver -> genericapiserver/api} 2017-01-03 14:54:03 +01:00
Mike Danese 161c391f44 autogenerated 2016-12-29 13:04:10 -08:00
Chao Xu 83752406d8 revert backward compatibility hacks (36004, 32751) that are no-longer needed in 1.6 2016-12-21 15:34:08 -08:00
Daniel Smith 4de1287eb2 Update OWNERS
Remove people probably not interested in this code
2016-12-19 16:22:41 -08:00
Antoine Pelisse f74183e138 Update OWNERS approvers and reviewers: pkg/registry 2016-12-19 16:22:40 -08:00
Monis Khan 91cb57d904
Remove dead code
Signed-off-by: Monis Khan <mkhan@redhat.com>
2016-12-15 13:37:35 -05:00
Dan Winship f369372dad Drop version-parsing from pkg/version
pkg/version is now just version constants, etc, not version parsing
2016-12-13 08:53:19 -05:00
Mike Danese c87de85347 autoupdate BUILD files 2016-12-12 13:30:07 -08:00
Monis Khan a6bafbacbf
Refactor REST storage to use generic defaults
Signed-off-by: Monis Khan <mkhan@redhat.com>
2016-12-08 17:24:21 -05:00
Wojciech Tyczynski 3432fea8b2 Pipe GetOptions to storage 2016-12-06 11:48:37 +01:00
Clayton Coleman 3454a8d52c
refactor: update bazel, codec, and gofmt 2016-12-03 19:10:53 -05:00
Clayton Coleman 5df8cc39c9
refactor: generated 2016-12-03 19:10:46 -05:00
Kubernetes Submit Queue ad72d1728c Merge pull request #37547 from sttts/sttts-cut-off-genericapserver-from-registry
Automatic merge from submit-queue

Cut genericapserver->registry dependency

Towards moving genericapiserver into staging.
2016-12-03 12:22:20 -08:00
Dr. Stefan Schimanski 1f5511b131 Move RESTStorageProvider interface into pkg/master 2016-12-03 18:35:15 +01:00
Wojciech Tyczynski ec247315be Handle RV in Get calls to storage interface. 2016-12-03 10:18:43 +01:00
Kubernetes Submit Queue cd560926bd Merge pull request #36889 from wojtek-t/reuse_fields_and_labels
Automatic merge from submit-queue

Reuse fields and labels

This should significantly reduce memory allocations in apiserver in large cluster.
Explanation:
- every kubelet is refreshing watch every 5-10 minutes (this generally is not causing relist - it just renews watch)
- that means, in 5000-node cluster, we are issuing ~10 watches per second
- since we don't have "watch heartbets", the watch is issued from previously received resourceVersion
- to make some assumption, let's assume pods are evenly spread across pods, and writes for them are evenly spread - that means, that a given kubelet is interested in 1 per 5000 pod changes
- with that assumption, each watch, has to process 2500 (on average) previous watch events
- for each of such even, we are currently computing fields.

This PR is fixing this problem.
2016-12-02 21:49:43 -08:00
Kubernetes Submit Queue 05af3abfdd Merge pull request #37721 from derekwaynecarr/fix-graceful-delete
Automatic merge from submit-queue

Fix logic error in graceful deletion

If a resource has the following criteria:

1. deletion timestamp is not nil
2. deletion graceperiod seconds as persisted in storage is 0

the resource could never be deleted as we always returned pending graceful.
2016-12-02 05:44:59 -08:00
Derek Carr 14730841f3 Fix logic in graceful deletion if existing grace period was 0 2016-12-01 14:24:50 -05:00
Kubernetes Submit Queue 985079a82f Merge pull request #37487 from wojtek-t/kubernetes_service
Automatic merge from submit-queue

Fix TestServiceAlloc flakes

Fix #37040
2016-11-29 17:04:04 -08:00
Wojciech Tyczynski 36e6cd19e1 Cache fields for filtering in watchCache. 2016-11-29 09:48:09 +01:00
Kubernetes Submit Queue 2421e1e829 Merge pull request #37189 from brendandburns/typo
Automatic merge from submit-queue

fix a typo I noticed while reading some code.
2016-11-28 11:44:31 -08:00
Wojciech Tyczynski 17606603d2 Fix TestServiceAlloc flakes 2016-11-25 14:50:40 +01:00
Clayton Coleman 35a6bfbcee
generated: refactor 2016-11-23 22:30:47 -06:00
Brendan Burns 55c7365953 fix a typo 2016-11-20 21:14:55 -08:00
Tim St. Clair 6e0702a50d Handle redirects in apiserver proxy handler 2016-11-04 12:26:24 -07:00
Mike Danese 3b6a067afc autogenerated 2016-10-21 17:32:32 -07:00
Kubernetes Submit Queue 850c586b69 Merge pull request #35218 from wojtek-t/get_to_list_support_resource_version
Automatic merge from submit-queue

Support resourceVersion in GetToList - unify interface of List and Ge…

This pretty much unifies the interface of List() and GetToList() methods of storage interface.

I'm going to use it in a subsequent PR to improve performance of the whole cluster.
2016-10-21 08:02:14 -07:00
Wojciech Tyczynski 93c008f8a4 Support resourceVersion in GetToList - unify interface of List and GetToList 2016-10-21 10:09:23 +02:00
Wojciech Tyczynski 9c91da7a22 More efficient selector 2016-10-20 15:16:58 +02:00
Wojciech Tyczynski 422121f93a Avoid unnecessary map allocation 2016-10-17 15:01:00 +02:00
Hongchao Deng 6f3ac807fd pass SelectionPredicate instead of Filter to storage layer 2016-09-26 09:47:19 -07:00
deads2k 561f8d75a5 move core resource registry packages 2016-09-21 10:11:50 -04:00
Janet Kuo 30512f909d Improve error message when kubectl rolling-update fail due to version skew
Print the real error message first, the workaround later
2016-09-16 13:00:55 -07:00
Chao Xu c4ea205aeb print instruction in case of failed kubectl 1.3 rolling-update against 1.4 cluster 2016-09-15 17:20:39 -07:00
Clayton Coleman acb4c00b39
EnableGarbageCollection should be a struct member on RESTOptions
Not a global. Now that we have RESTOptions this was an easy change.
2016-09-15 00:09:28 -04:00
Timothy St. Clair 5b11b5984e Fixes to cleanup storage clients during UT.
During etcd3.clientv3 integration we had discovered we were leaking connections
2016-09-14 07:27:21 -05:00
Timothy St. Clair 9f3841b452 Revert "Revert "Enable v3 Client as the default on UTs""
This reverts commit 9dcef2e3cd.
2016-09-14 07:27:21 -05:00
Kubernetes Submit Queue 7536eb2691 Merge pull request #32351 from caesarxuchao/fix-finalizer
Automatic merge from submit-queue

Make sure finalizers prevent deletion on storage that supports graceful deletion

Fixing bug:
Non-empty Finalizers fails to prevent a pod from being deleted, if deleteOptions.GracefulPeriod=0. See https://github.com/kubernetes/kubernetes/issues/32157#issuecomment-245778483

We didn't hit any issue with orphan finalizer because all our tests set finalizers on RC or RS, whose storage doesn't support graceful deletion.

cc @thockin @lavalamp
2016-09-09 13:47:47 -07:00
Chao Xu fcf8853dd7 make sure finalizer prevents deletion on storage that supports graceful deletion 2016-09-08 21:00:49 -07:00
Kubernetes Submit Queue c27326a26c Merge pull request #31189 from hongchaodeng/r1
Automatic merge from submit-queue

api storage: Decouple Decorator from Filter

Continue #28249

What?
This PR decouples Decorator from Filter, i.e. remove Decorator in createFilter().
- For List, Decorator is called on returned list object.
- For Watch, we implement a new watcher to pipe through decorator. Error will be returned as a watch event.

Why?
- We want to change filter to SelectionPredicate struct. But Decorator is designed to be coupled with filtering.
- Per the discussion in #28249, decorator shouldn't be coupled to filter and error from Decorator should be returned instead of assuming false filtering.
2016-09-08 04:25:05 -07:00
Kubernetes Submit Queue 9f58a867e1 Merge pull request #31522 from krousey/path_validation
Automatic merge from submit-queue

Split path validation into a separate library

This PR splits path segment validation into it's own package. This cuts off one of the restclient's dependency paths to some docker packages, and completely eliminates its dependency on go-restful swagger validation.


cc @kubernetes/sig-api-machinery
2016-09-07 10:14:32 -07:00
vefimova cc64faf209 Added printing of clarification for `object creation` request in case of object is in the process of graceful deletion 2016-09-01 16:39:48 +00:00
Kris e87edf9bd5 Split path validation into a separate library 2016-08-26 08:05:20 -07:00
Hongchao Deng 9131fbd446 refactor destroy func in unit testing 2016-08-25 22:57:28 -07:00
Kubernetes Submit Queue 40efde7e0a Merge pull request #31390 from hongchaodeng/fix
Automatic merge from submit-queue

return destroy func to clean up internal resources of storage

What?
Provide a destroy func to clean up internal resources of storage.
It changes **unit tests** to clean up resources. (Maybe fix integration test in another PR.)

Why?
Although apiserver is designed to be long running, there are some cases that it's not.
See https://github.com/kubernetes/kubernetes/issues/31262#issuecomment-242208771
We need to gracefully shutdown and clean up resources.
2016-08-25 16:44:10 -07:00
Kubernetes Submit Queue b44b716965 Merge pull request #31248 from wojtek-t/better_selectable_fields
Automatic merge from submit-queue

Avoid unnecessary copies & allocations in field selectors
2016-08-25 09:01:44 -07:00
Hongchao Deng 9fc0e1e98d return destroy func to clean up internal resources of storage 2016-08-25 08:32:21 -07:00