Commit Graph

45 Commits

Author SHA1 Message Date
deads2k
9913ebf079 add quota test for creating update requests 2016-08-22 10:36:41 -04:00
Kubernetes Submit Queue
4145824911 Merge pull request #30907 from deads2k/fix-quota-updates
Automatic merge from submit-queue

only compute delta on non-creating updates

If you're issuing an update that can cause a create, the quota admission charge should be based on the create cost, otherwise you always end up with zero.

@derekwaynecarr ptal, blocker bug.
2016-08-20 16:16:02 -07:00
deads2k
44808c64ae only compute delta on non-creating updates 2016-08-18 13:41:33 -04:00
derekwaynecarr
307832dbec Quota usage checking ignores unrelated resources 2016-08-17 16:25:25 -04:00
derekwaynecarr
5cca4b07c6 Quota admission errors if usage is negative 2016-08-11 11:26:59 -04:00
derekwaynecarr
305411b59b Fix bug in node port counting in quota not counting multi-node ports 2016-07-22 13:56:55 -04:00
deads2k
ada37c2163 allow lock acquisition injection for quota admission 2016-07-06 09:39:42 -04:00
David McMahon
ef0c9f0c5b Remove "All rights reserved" from all the headers. 2016-06-29 17:47:36 -07:00
deads2k
a28cf3963b refactor quota evaluation to cleanly abstract the quota access 2016-06-28 11:38:18 -04:00
derekwaynecarr
ce44b3b98a Quota can look for a previous object from admission rather than do a lookup 2016-06-13 09:50:53 -04:00
Jordan Liggitt
29252acd1a Change rest storage Update interface to retrieve updated object
Add OldObject to admission attributes

Update resthandler Patch/Update admission plumbing
2016-05-23 21:09:26 -04:00
derekwaynecarr
8b8a22b143 pod constraints func for quota validates resources 2016-05-11 14:30:46 -04:00
derekwaynecarr
fc3e71894d Improve quota integration test to not use events, reduce number of pods provisioned 2016-05-10 19:50:36 -04:00
derekwaynecarr
ca7a8b50e6 Sort resources in quota errors to avoid duplicate events 2016-05-06 17:44:28 -04:00
deads2k
0061479890 fully qualify admission resources and kinds 2016-04-26 07:55:33 -04:00
deads2k
d3c6363093 use single writer to improve quota performance 2016-04-25 10:42:26 -04:00
Chao Xu
8537095415 use fully qualified resource in fake clients actions 2016-04-20 19:44:40 -07:00
Michal Minar
2601ee56ab Set a missing namespace on object to admit
Custom quota evaluators may need to query a target namespace of an input
object during quota admission check. For this, namespace needs to be
known.

Signed-off-by: Michal Minar <miminar@redhat.com>
2016-03-15 17:03:55 +01:00
derekwaynecarr
af85fb57c3 Make ResourceQuota admission and controller work generically 2016-02-26 20:34:15 -05:00
Chao Xu
ad46715f51 generate fake client for release_1_2 2016-02-17 16:10:02 -08:00
Chao Xu
cddd7b56a4 replace client with clientset in kubelet and other places 2016-02-02 20:28:45 -08:00
deads2k
3f045cf168 udpate admission for API groups 2015-12-07 08:55:01 -05:00
derekwaynecarr
9ce6ef87ac Unnecessary updates to ResourceQuota when doing UPDATE to non-pod resources 2015-11-10 12:01:08 -05:00
eulerzgy
4ed5f9d240 adjust package name for pkg/controller directory 2015-10-12 09:51:27 +08:00
hurf
5cc909afe7 Remove type validation in resource.Quantity.Add
The type validation is unnecessary for add and will cause problem.
Type will always keep unchanged after new amount is added.
2015-09-22 21:07:31 +08: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
derekwaynecarr
2e76842eb7 Update resource quota for requests 2015-09-03 14:24:59 -04:00
Kris Rousey
ae6c64d9bb Moving everyone to unversioned client 2015-08-18 10:23:03 -07:00
Mike Danese
8e33cbfa28 rewrite go imports 2015-08-05 17:30:03 -07:00
Tim Hockin
1c3233a1d4 Remove v1beta3 2015-07-23 17:21:27 -07:00
derekwaynecarr
f6fb72ec51 Admission control attributes has access to resource name 2015-06-23 13:54:55 -04:00
derekwaynecarr
795e444ba3 ResourceQuota should ignore subresources 2015-06-18 16:03:40 -04:00
derekwaynecarr
fce7adf3e7 Admission control exposes subresource 2015-06-18 15:00:46 -04:00
Cesar Wong
68ad63b5e2 Add operation checking to admission control handlers
Adds a new method to the handler interface that returns true only if the
admission control handler handles that operation.
2015-05-21 13:51:43 -04:00
Paul Weil
aaeb1dad93 expose user info to admission controllers 2015-05-13 21:31:51 -04:00
Eric Paris
6b3a6e6b98 Make copyright ownership statement generic
Instead of saying "Google Inc." (which is not always correct) say "The
Kubernetes Authors", which is generic.
2015-05-01 17:49:56 -04:00
Vish Kannan
ee06097c07 Merge pull request #7003 from derekwaynecarr/enforce_unbounded
Reject unbounded cpu and memory pods if quota is restricting it
2015-04-22 11:19:52 -07:00
derekwaynecarr
06eb45fb75 ResourceQuota add object count support for secret and volume claims 2015-04-21 09:49:40 -04:00
derekwaynecarr
75482cabb4 Reject unbounded cpu and memory pods if quota is restricting it 2015-04-17 17:02:47 -04:00
derekwaynecarr
81dcd8c836 Improve error message when name is omitted but generateName is available 2015-04-16 13:06:19 -04:00
Clayton Coleman
51db3bd654 Create a new testclient package that can be backed by disk files
Standardize how our fakes are used so that a test case can use a
simpler mechanism for providing large, complex data sets, as well
as represent queries over time.
2015-04-07 14:56:15 -04:00
Vishnu Kannan
d0524d4778 Rename ResourceRequirementSpec to ResourceRequirements. 2015-02-09 23:19:38 +00:00
Vishnu Kannan
5e36f63f8b Adding ResourceRequirementSpec to v1beta1, v1beta2, and v1beta3 APIs. The old resource
quantities 'CPU' and 'Memory' will be preserved until support for v1beta1 and v1beta2 APIs are
dropped.
Improved resource validation in the process.
2015-02-01 02:19:55 +00:00
derekwaynecarr
9674f08504 Added unit tests for incrementing usage 2015-01-28 15:03:19 -05:00
derekwaynecarr
4887d71c51 Implement resource quota admission plugin 2015-01-28 15:03:19 -05:00