|
| 1 | +/* |
| 2 | + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except |
| 3 | + * in compliance with the License. You may obtain a copy of the License at |
| 4 | + * |
| 5 | + * http://www.apache.org/licenses/LICENSE-2.0 |
| 6 | + * |
| 7 | + * Unless required by applicable law or agreed to in writing, software distributed under the License |
| 8 | + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express |
| 9 | + * or implied. See the License for the specific language governing permissions and limitations under |
| 10 | + * the License. |
| 11 | + */ |
| 12 | +/* |
| 13 | + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ |
| 14 | + * Modify at your own risk. |
| 15 | + */ |
| 16 | + |
| 17 | +package com.google.api.services.container.model; |
| 18 | + |
| 19 | +/** |
| 20 | + * TopologyManager defines the configuration options for Topology Manager feature. See |
| 21 | + * https://kubernetes.io/docs/tasks/administer-cluster/topology-manager/ |
| 22 | + * |
| 23 | + * <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is |
| 24 | + * transmitted over HTTP when working with the Kubernetes Engine API. For a detailed explanation |
| 25 | + * see: |
| 26 | + * <a href="https://developers.google.com/api-client-library/java/google-http-java-client/json">https://developers.google.com/api-client-library/java/google-http-java-client/json</a> |
| 27 | + * </p> |
| 28 | + * |
| 29 | + * @author Google, Inc. |
| 30 | + */ |
| 31 | +@SuppressWarnings("javadoc") |
| 32 | +public final class TopologyManager extends com.google.api.client.json.GenericJson { |
| 33 | + |
| 34 | + /** |
| 35 | + * Configures the strategy for resource alignment. Allowed values are: * none: the default policy, |
| 36 | + * and does not perform any topology alignment. * restricted: the topology manager stores the |
| 37 | + * preferred NUMA node affinity for the container, and will reject the pod if the affinity if not |
| 38 | + * preferred. * best-effort: the topology manager stores the preferred NUMA node affinity for the |
| 39 | + * container. If the affinity is not preferred, the topology manager will admit the pod to the |
| 40 | + * node anyway. * single-numa-node: the topology manager determines if the single NUMA node |
| 41 | + * affinity is possible. If it is, Topology Manager will store this and the Hint Providers can |
| 42 | + * then use this information when making the resource allocation decision. If, however, this is |
| 43 | + * not possible then the Topology Manager will reject the pod from the node. This will result in a |
| 44 | + * pod in a Terminated state with a pod admission failure. The default policy value is 'none' if |
| 45 | + * unspecified. Details about each strategy can be found |
| 46 | + * [here](https://kubernetes.io/docs/tasks/administer-cluster/topology-manager/#topology-manager- |
| 47 | + * policies). |
| 48 | + * The value may be {@code null}. |
| 49 | + */ |
| 50 | + @com.google.api.client.util.Key |
| 51 | + private java.lang.String policy; |
| 52 | + |
| 53 | + /** |
| 54 | + * The Topology Manager aligns resources in following scopes: * container * pod The default scope |
| 55 | + * is 'container' if unspecified. See https://kubernetes.io/docs/tasks/administer- |
| 56 | + * cluster/topology-manager/#topology-manager-scopes |
| 57 | + * The value may be {@code null}. |
| 58 | + */ |
| 59 | + @com.google.api.client.util.Key |
| 60 | + private java.lang.String scope; |
| 61 | + |
| 62 | + /** |
| 63 | + * Configures the strategy for resource alignment. Allowed values are: * none: the default policy, |
| 64 | + * and does not perform any topology alignment. * restricted: the topology manager stores the |
| 65 | + * preferred NUMA node affinity for the container, and will reject the pod if the affinity if not |
| 66 | + * preferred. * best-effort: the topology manager stores the preferred NUMA node affinity for the |
| 67 | + * container. If the affinity is not preferred, the topology manager will admit the pod to the |
| 68 | + * node anyway. * single-numa-node: the topology manager determines if the single NUMA node |
| 69 | + * affinity is possible. If it is, Topology Manager will store this and the Hint Providers can |
| 70 | + * then use this information when making the resource allocation decision. If, however, this is |
| 71 | + * not possible then the Topology Manager will reject the pod from the node. This will result in a |
| 72 | + * pod in a Terminated state with a pod admission failure. The default policy value is 'none' if |
| 73 | + * unspecified. Details about each strategy can be found |
| 74 | + * [here](https://kubernetes.io/docs/tasks/administer-cluster/topology-manager/#topology-manager- |
| 75 | + * policies). |
| 76 | + * @return value or {@code null} for none |
| 77 | + */ |
| 78 | + public java.lang.String getPolicy() { |
| 79 | + return policy; |
| 80 | + } |
| 81 | + |
| 82 | + /** |
| 83 | + * Configures the strategy for resource alignment. Allowed values are: * none: the default policy, |
| 84 | + * and does not perform any topology alignment. * restricted: the topology manager stores the |
| 85 | + * preferred NUMA node affinity for the container, and will reject the pod if the affinity if not |
| 86 | + * preferred. * best-effort: the topology manager stores the preferred NUMA node affinity for the |
| 87 | + * container. If the affinity is not preferred, the topology manager will admit the pod to the |
| 88 | + * node anyway. * single-numa-node: the topology manager determines if the single NUMA node |
| 89 | + * affinity is possible. If it is, Topology Manager will store this and the Hint Providers can |
| 90 | + * then use this information when making the resource allocation decision. If, however, this is |
| 91 | + * not possible then the Topology Manager will reject the pod from the node. This will result in a |
| 92 | + * pod in a Terminated state with a pod admission failure. The default policy value is 'none' if |
| 93 | + * unspecified. Details about each strategy can be found |
| 94 | + * [here](https://kubernetes.io/docs/tasks/administer-cluster/topology-manager/#topology-manager- |
| 95 | + * policies). |
| 96 | + * @param policy policy or {@code null} for none |
| 97 | + */ |
| 98 | + public TopologyManager setPolicy(java.lang.String policy) { |
| 99 | + this.policy = policy; |
| 100 | + return this; |
| 101 | + } |
| 102 | + |
| 103 | + /** |
| 104 | + * The Topology Manager aligns resources in following scopes: * container * pod The default scope |
| 105 | + * is 'container' if unspecified. See https://kubernetes.io/docs/tasks/administer- |
| 106 | + * cluster/topology-manager/#topology-manager-scopes |
| 107 | + * @return value or {@code null} for none |
| 108 | + */ |
| 109 | + public java.lang.String getScope() { |
| 110 | + return scope; |
| 111 | + } |
| 112 | + |
| 113 | + /** |
| 114 | + * The Topology Manager aligns resources in following scopes: * container * pod The default scope |
| 115 | + * is 'container' if unspecified. See https://kubernetes.io/docs/tasks/administer- |
| 116 | + * cluster/topology-manager/#topology-manager-scopes |
| 117 | + * @param scope scope or {@code null} for none |
| 118 | + */ |
| 119 | + public TopologyManager setScope(java.lang.String scope) { |
| 120 | + this.scope = scope; |
| 121 | + return this; |
| 122 | + } |
| 123 | + |
| 124 | + @Override |
| 125 | + public TopologyManager set(String fieldName, Object value) { |
| 126 | + return (TopologyManager) super.set(fieldName, value); |
| 127 | + } |
| 128 | + |
| 129 | + @Override |
| 130 | + public TopologyManager clone() { |
| 131 | + return (TopologyManager) super.clone(); |
| 132 | + } |
| 133 | + |
| 134 | +} |
0 commit comments