summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorderekwaynecarr <decarr@redhat.com>2016-02-22 11:16:46 -0500
committerderekwaynecarr <decarr@redhat.com>2016-02-26 20:34:15 -0500
commitb60f66576940b5e39abb0bc816f9e64a5e8b119a (patch)
treefb069564d32006e3cd78b6eff0dd2682296b62dc
parent3a062fc5b440a41a4253b27278cdcbc1c84c2a00 (diff)
Update resource quota scope documentation
-rw-r--r--resource-quota-scoping.md32
1 files changed, 16 insertions, 16 deletions
diff --git a/resource-quota-scoping.md b/resource-quota-scoping.md
index 7ed499f8..02b4e157 100644
--- a/resource-quota-scoping.md
+++ b/resource-quota-scoping.md
@@ -112,11 +112,11 @@ Support the following resources that can be tracked by quota.
| Resource Name | Description |
| ------------- | ----------- |
| cpu | total cpu requests (backwards compatibility) |
-| cpu.request | total cpu requests |
-| cpu.limit | total cpu limits |
| memory | total memory requests (backwards compatibility) |
-| memory.request | total memory requests |
-| memory.limit | total memory limits |
+| requests.cpu | total cpu requests |
+| requests.memory | total memory requests |
+| limits.cpu | total cpu limits |
+| limits.memory | total memory limits |
### Resource Quota Scopes
@@ -145,22 +145,22 @@ A `Terminating`, `NotTerminating`, `NotBestEffort` scope restricts a quota to
tracking the following resources:
* pod
-* memory, memory.request, memory.limit
-* cpu, cpu.request, cpu.limit
+* memory, requests.memory, limits.memory
+* cpu, requests.cpu, limits.cpu
## Data Model Impact
```
// The following identify resource constants for Kubernetes object types
const (
- // CPU Request, in cores
- ResourceCPURequest ResourceName = "cpu.request"
- // CPU Limit, in bytes
- ResourceCPULimit ResourceName = "cpu.limit"
- // Memory Request, in bytes
- ResourceMemoryRequest ResourceName = "memory.request"
- // Memory Limit, in bytes
- ResourceMemoryLimit ResourceName = "memory.limit"
+ // CPU request, in cores. (500m = .5 cores)
+ ResourceRequestsCPU ResourceName = "requests.cpu"
+ // Memory request, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024)
+ ResourceRequestsMemory ResourceName = "requests.memory"
+ // CPU limit, in cores. (500m = .5 cores)
+ ResourceLimitsCPU ResourceName = "limits.cpu"
+ // Memory limit, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024)
+ ResourceLimitsMemory ResourceName = "limits.memory"
)
// A scope is a filter that matches an object
@@ -178,8 +178,8 @@ const (
type ResourceQuotaSpec struct {
// Hard is the set of desired hard limits for each named resource
Hard ResourceList `json:"hard,omitempty"`
- // Scopes is the set of filters that must match an object for it to be
- // tracked by the quota
+ // A collection of filters that must match each object tracked by a quota.
+ // If not specified, the quota matches all objects.
Scopes []ResourceQuotaScope `json:"scopes,omitempty"`
}
```