Class SchedulerSpec
- java.lang.Object
-
- io.fabric8.openshift.api.model.config.v1.SchedulerSpec
-
- All Implemented Interfaces:
io.fabric8.kubernetes.api.builder.Editable<SchedulerSpecBuilder>,io.fabric8.kubernetes.api.model.KubernetesResource,Serializable
@Generated("io.fabric8.kubernetes.schema.generator.model.ModelGenerator") public class SchedulerSpec extends Object implements io.fabric8.kubernetes.api.builder.Editable<SchedulerSpecBuilder>, io.fabric8.kubernetes.api.model.KubernetesResource
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SchedulerSpec()No args constructor for use in serializationSchedulerSpec(String defaultNodeSelector, Boolean mastersSchedulable, ConfigMapNameReference policy, String profile, ProfileCustomizations profileCustomizations)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SchedulerSpecBuilderedit()Map<String,Object>getAdditionalProperties()StringgetDefaultNodeSelector()defaultNodeSelector helps set the cluster-wide default node selector to restrict pod placement to specific nodes.BooleangetMastersSchedulable()mastersSchedulable allows masters nodes to be schedulable.ConfigMapNameReferencegetPolicy()StringgetProfile()profile sets which scheduling profile should be set in order to configure scheduling decisions for new pods.ProfileCustomizationsgetProfileCustomizations()voidsetAdditionalProperties(Map<String,Object> additionalProperties)voidsetAdditionalProperty(String name, Object value)voidsetDefaultNodeSelector(String defaultNodeSelector)defaultNodeSelector helps set the cluster-wide default node selector to restrict pod placement to specific nodes.voidsetMastersSchedulable(Boolean mastersSchedulable)mastersSchedulable allows masters nodes to be schedulable.voidsetPolicy(ConfigMapNameReference policy)voidsetProfile(String profile)profile sets which scheduling profile should be set in order to configure scheduling decisions for new pods.voidsetProfileCustomizations(ProfileCustomizations profileCustomizations)SchedulerSpecBuildertoBuilder()
-
-
-
Constructor Detail
-
SchedulerSpec
public SchedulerSpec()
No args constructor for use in serialization
-
SchedulerSpec
public SchedulerSpec(String defaultNodeSelector, Boolean mastersSchedulable, ConfigMapNameReference policy, String profile, ProfileCustomizations profileCustomizations)
-
-
Method Detail
-
getDefaultNodeSelector
public String getDefaultNodeSelector()
defaultNodeSelector helps set the cluster-wide default node selector to restrict pod placement to specific nodes. This is applied to the pods created in all namespaces and creates an intersection with any existing nodeSelectors already set on a pod, additionally constraining that pod's selector. For example, defaultNodeSelector: "type=user-node,region=east" would set nodeSelector field in pod spec to "type=user-node,region=east" to all pods created in all namespaces. Namespaces having project-wide node selectors won't be impacted even if this field is set. This adds an annotation section to the namespace. For example, if a new namespace is created with node-selector='type=user-node,region=east', the annotation openshift.io/node-selector: type=user-node,region=east gets added to the project. When the openshift.io/node-selector annotation is set on the project the value is used in preference to the value we are setting for defaultNodeSelector field. For instance, openshift.io/node-selector: "type=user-node,region=west" means that the default of "type=user-node,region=east" set in defaultNodeSelector would not be applied.
-
setDefaultNodeSelector
public void setDefaultNodeSelector(String defaultNodeSelector)
defaultNodeSelector helps set the cluster-wide default node selector to restrict pod placement to specific nodes. This is applied to the pods created in all namespaces and creates an intersection with any existing nodeSelectors already set on a pod, additionally constraining that pod's selector. For example, defaultNodeSelector: "type=user-node,region=east" would set nodeSelector field in pod spec to "type=user-node,region=east" to all pods created in all namespaces. Namespaces having project-wide node selectors won't be impacted even if this field is set. This adds an annotation section to the namespace. For example, if a new namespace is created with node-selector='type=user-node,region=east', the annotation openshift.io/node-selector: type=user-node,region=east gets added to the project. When the openshift.io/node-selector annotation is set on the project the value is used in preference to the value we are setting for defaultNodeSelector field. For instance, openshift.io/node-selector: "type=user-node,region=west" means that the default of "type=user-node,region=east" set in defaultNodeSelector would not be applied.
-
getMastersSchedulable
public Boolean getMastersSchedulable()
mastersSchedulable allows masters nodes to be schedulable. When this flag is turned on, all the master nodes in the cluster will be made schedulable, so that workload pods can run on them. The default value for this field is false, meaning none of the master nodes are schedulable. Important Note: Once the workload pods start running on the master nodes, extreme care must be taken to ensure that cluster-critical control plane components are not impacted. Please turn on this field after doing due diligence.
-
setMastersSchedulable
public void setMastersSchedulable(Boolean mastersSchedulable)
mastersSchedulable allows masters nodes to be schedulable. When this flag is turned on, all the master nodes in the cluster will be made schedulable, so that workload pods can run on them. The default value for this field is false, meaning none of the master nodes are schedulable. Important Note: Once the workload pods start running on the master nodes, extreme care must be taken to ensure that cluster-critical control plane components are not impacted. Please turn on this field after doing due diligence.
-
getPolicy
public ConfigMapNameReference getPolicy()
-
setPolicy
public void setPolicy(ConfigMapNameReference policy)
-
getProfile
public String getProfile()
profile sets which scheduling profile should be set in order to configure scheduling decisions for new pods.Valid values are "LowNodeUtilization", "HighNodeUtilization", "NoScoring" Defaults to "LowNodeUtilization"
-
setProfile
public void setProfile(String profile)
profile sets which scheduling profile should be set in order to configure scheduling decisions for new pods.Valid values are "LowNodeUtilization", "HighNodeUtilization", "NoScoring" Defaults to "LowNodeUtilization"
-
getProfileCustomizations
public ProfileCustomizations getProfileCustomizations()
-
setProfileCustomizations
public void setProfileCustomizations(ProfileCustomizations profileCustomizations)
-
edit
public SchedulerSpecBuilder edit()
- Specified by:
editin interfaceio.fabric8.kubernetes.api.builder.Editable<SchedulerSpecBuilder>
-
toBuilder
public SchedulerSpecBuilder toBuilder()
-
-