Package net.stickycode.kuuty.model.v18
Class IoK8sApiCoreV1ServiceSpec
- java.lang.Object
-
- net.stickycode.kuuty.model.v18.IoK8sApiCoreV1ServiceSpec
-
@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", date="2020-11-26T11:01:11.402583+13:00[Pacific/Auckland]") public class IoK8sApiCoreV1ServiceSpec extends Object
ServiceSpec describes the attributes that a user creates on a service.
-
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_CLUSTER_I_Pstatic StringJSON_PROPERTY_EXTERNAL_I_PSstatic StringJSON_PROPERTY_EXTERNAL_NAMEstatic StringJSON_PROPERTY_EXTERNAL_TRAFFIC_POLICYstatic StringJSON_PROPERTY_HEALTH_CHECK_NODE_PORTstatic StringJSON_PROPERTY_IP_FAMILYstatic StringJSON_PROPERTY_LOAD_BALANCER_I_Pstatic StringJSON_PROPERTY_LOAD_BALANCER_SOURCE_RANGESstatic StringJSON_PROPERTY_PORTSstatic StringJSON_PROPERTY_PUBLISH_NOT_READY_ADDRESSESstatic StringJSON_PROPERTY_SELECTORstatic StringJSON_PROPERTY_SESSION_AFFINITYstatic StringJSON_PROPERTY_SESSION_AFFINITY_CONFIGstatic StringJSON_PROPERTY_TOPOLOGY_KEYSstatic StringJSON_PROPERTY_TYPE
-
Constructor Summary
Constructors Constructor Description IoK8sApiCoreV1ServiceSpec()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IoK8sApiCoreV1ServiceSpecaddExternalIPsItem(String externalIPsItem)IoK8sApiCoreV1ServiceSpecaddLoadBalancerSourceRangesItem(String loadBalancerSourceRangesItem)IoK8sApiCoreV1ServiceSpecaddPortsItem(IoK8sApiCoreV1ServicePort portsItem)IoK8sApiCoreV1ServiceSpecaddTopologyKeysItem(String topologyKeysItem)IoK8sApiCoreV1ServiceSpecclusterIP(String clusterIP)booleanequals(Object o)IoK8sApiCoreV1ServiceSpecexternalIPs(List<String> externalIPs)IoK8sApiCoreV1ServiceSpecexternalName(String externalName)IoK8sApiCoreV1ServiceSpecexternalTrafficPolicy(String externalTrafficPolicy)StringgetClusterIP()clusterIP is the IP address of the service and is usually assigned randomly by the master.List<String>getExternalIPs()externalIPs is a list of IP addresses for which nodes in the cluster will also accept traffic for this service.StringgetExternalName()externalName is the external reference that kubedns or equivalent will return as a CNAME record for this service.StringgetExternalTrafficPolicy()externalTrafficPolicy denotes if this Service desires to route external traffic to node-local or cluster-wide endpoints.IntegergetHealthCheckNodePort()healthCheckNodePort specifies the healthcheck nodePort for the service.StringgetIpFamily()ipFamily specifies whether this Service has a preference for a particular IP family (e.g.StringgetLoadBalancerIP()Only applies to Service Type: LoadBalancer LoadBalancer will get created with the IP specified in this field.List<String>getLoadBalancerSourceRanges()If specified and supported by the platform, this will restrict traffic through the cloud-provider load-balancer will be restricted to the specified client IPs.List<IoK8sApiCoreV1ServicePort>getPorts()The list of ports that are exposed by this service.BooleangetPublishNotReadyAddresses()publishNotReadyAddresses, when set to true, indicates that DNS implementations must publish the notReadyAddresses of subsets for the Endpoints associated with the Service.Map<String,String>getSelector()Route service traffic to pods with label keys and values matching this selector.StringgetSessionAffinity()Supports \"ClientIP\" and \"None\".IoK8sApiCoreV1SessionAffinityConfiggetSessionAffinityConfig()Get sessionAffinityConfigList<String>getTopologyKeys()topologyKeys is a preference-order list of topology keys which implementations of services should use to preferentially sort endpoints when accessing this Service, it can not be used at the same time as externalTrafficPolicy=Local.StringgetType()type determines how the Service is exposed.inthashCode()IoK8sApiCoreV1ServiceSpechealthCheckNodePort(Integer healthCheckNodePort)IoK8sApiCoreV1ServiceSpecipFamily(String ipFamily)IoK8sApiCoreV1ServiceSpecloadBalancerIP(String loadBalancerIP)IoK8sApiCoreV1ServiceSpecloadBalancerSourceRanges(List<String> loadBalancerSourceRanges)IoK8sApiCoreV1ServiceSpecports(List<IoK8sApiCoreV1ServicePort> ports)IoK8sApiCoreV1ServiceSpecpublishNotReadyAddresses(Boolean publishNotReadyAddresses)IoK8sApiCoreV1ServiceSpecputSelectorItem(String key, String selectorItem)IoK8sApiCoreV1ServiceSpecselector(Map<String,String> selector)IoK8sApiCoreV1ServiceSpecsessionAffinity(String sessionAffinity)IoK8sApiCoreV1ServiceSpecsessionAffinityConfig(IoK8sApiCoreV1SessionAffinityConfig sessionAffinityConfig)voidsetClusterIP(String clusterIP)voidsetExternalIPs(List<String> externalIPs)voidsetExternalName(String externalName)voidsetExternalTrafficPolicy(String externalTrafficPolicy)voidsetHealthCheckNodePort(Integer healthCheckNodePort)voidsetIpFamily(String ipFamily)voidsetLoadBalancerIP(String loadBalancerIP)voidsetLoadBalancerSourceRanges(List<String> loadBalancerSourceRanges)voidsetPorts(List<IoK8sApiCoreV1ServicePort> ports)voidsetPublishNotReadyAddresses(Boolean publishNotReadyAddresses)voidsetSelector(Map<String,String> selector)voidsetSessionAffinity(String sessionAffinity)voidsetSessionAffinityConfig(IoK8sApiCoreV1SessionAffinityConfig sessionAffinityConfig)voidsetTopologyKeys(List<String> topologyKeys)voidsetType(String type)IoK8sApiCoreV1ServiceSpectopologyKeys(List<String> topologyKeys)StringtoString()IoK8sApiCoreV1ServiceSpectype(String type)
-
-
-
Field Detail
-
JSON_PROPERTY_CLUSTER_I_P
public static final String JSON_PROPERTY_CLUSTER_I_P
- See Also:
- Constant Field Values
-
JSON_PROPERTY_EXTERNAL_I_PS
public static final String JSON_PROPERTY_EXTERNAL_I_PS
- See Also:
- Constant Field Values
-
JSON_PROPERTY_EXTERNAL_NAME
public static final String JSON_PROPERTY_EXTERNAL_NAME
- See Also:
- Constant Field Values
-
JSON_PROPERTY_EXTERNAL_TRAFFIC_POLICY
public static final String JSON_PROPERTY_EXTERNAL_TRAFFIC_POLICY
- See Also:
- Constant Field Values
-
JSON_PROPERTY_HEALTH_CHECK_NODE_PORT
public static final String JSON_PROPERTY_HEALTH_CHECK_NODE_PORT
- See Also:
- Constant Field Values
-
JSON_PROPERTY_IP_FAMILY
public static final String JSON_PROPERTY_IP_FAMILY
- See Also:
- Constant Field Values
-
JSON_PROPERTY_LOAD_BALANCER_I_P
public static final String JSON_PROPERTY_LOAD_BALANCER_I_P
- See Also:
- Constant Field Values
-
JSON_PROPERTY_LOAD_BALANCER_SOURCE_RANGES
public static final String JSON_PROPERTY_LOAD_BALANCER_SOURCE_RANGES
- See Also:
- Constant Field Values
-
JSON_PROPERTY_PORTS
public static final String JSON_PROPERTY_PORTS
- See Also:
- Constant Field Values
-
JSON_PROPERTY_PUBLISH_NOT_READY_ADDRESSES
public static final String JSON_PROPERTY_PUBLISH_NOT_READY_ADDRESSES
- See Also:
- Constant Field Values
-
JSON_PROPERTY_SELECTOR
public static final String JSON_PROPERTY_SELECTOR
- See Also:
- Constant Field Values
-
JSON_PROPERTY_SESSION_AFFINITY
public static final String JSON_PROPERTY_SESSION_AFFINITY
- See Also:
- Constant Field Values
-
JSON_PROPERTY_SESSION_AFFINITY_CONFIG
public static final String JSON_PROPERTY_SESSION_AFFINITY_CONFIG
- See Also:
- Constant Field Values
-
JSON_PROPERTY_TOPOLOGY_KEYS
public static final String JSON_PROPERTY_TOPOLOGY_KEYS
- See Also:
- Constant Field Values
-
JSON_PROPERTY_TYPE
public static final String JSON_PROPERTY_TYPE
- See Also:
- Constant Field Values
-
-
Method Detail
-
clusterIP
public IoK8sApiCoreV1ServiceSpec clusterIP(String clusterIP)
-
getClusterIP
@Nullable public String getClusterIP()
clusterIP is the IP address of the service and is usually assigned randomly by the master. If an address is specified manually and is not in use by others, it will be allocated to the service; otherwise, creation of the service will fail. This field can not be changed through updates. Valid values are \"None\", empty string (\"\"), or a valid IP address. \"None\" can be specified for headless services when proxying is not required. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies- Returns:
- clusterIP
-
setClusterIP
public void setClusterIP(String clusterIP)
-
externalIPs
public IoK8sApiCoreV1ServiceSpec externalIPs(List<String> externalIPs)
-
addExternalIPsItem
public IoK8sApiCoreV1ServiceSpec addExternalIPsItem(String externalIPsItem)
-
getExternalIPs
@Nullable public List<String> getExternalIPs()
externalIPs is a list of IP addresses for which nodes in the cluster will also accept traffic for this service. These IPs are not managed by Kubernetes. The user is responsible for ensuring that traffic arrives at a node with this IP. A common example is external load-balancers that are not part of the Kubernetes system.- Returns:
- externalIPs
-
externalName
public IoK8sApiCoreV1ServiceSpec externalName(String externalName)
-
getExternalName
@Nullable public String getExternalName()
externalName is the external reference that kubedns or equivalent will return as a CNAME record for this service. No proxying will be involved. Must be a valid RFC-1123 hostname (https://tools.ietf.org/html/rfc1123) and requires Type to be ExternalName.- Returns:
- externalName
-
setExternalName
public void setExternalName(String externalName)
-
externalTrafficPolicy
public IoK8sApiCoreV1ServiceSpec externalTrafficPolicy(String externalTrafficPolicy)
-
getExternalTrafficPolicy
@Nullable public String getExternalTrafficPolicy()
externalTrafficPolicy denotes if this Service desires to route external traffic to node-local or cluster-wide endpoints. \"Local\" preserves the client source IP and avoids a second hop for LoadBalancer and Nodeport type services, but risks potentially imbalanced traffic spreading. \"Cluster\" obscures the client source IP and may cause a second hop to another node, but should have good overall load-spreading.- Returns:
- externalTrafficPolicy
-
setExternalTrafficPolicy
public void setExternalTrafficPolicy(String externalTrafficPolicy)
-
healthCheckNodePort
public IoK8sApiCoreV1ServiceSpec healthCheckNodePort(Integer healthCheckNodePort)
-
getHealthCheckNodePort
@Nullable public Integer getHealthCheckNodePort()
healthCheckNodePort specifies the healthcheck nodePort for the service. If not specified, HealthCheckNodePort is created by the service api backend with the allocated nodePort. Will use user-specified nodePort value if specified by the client. Only effects when Type is set to LoadBalancer and ExternalTrafficPolicy is set to Local.- Returns:
- healthCheckNodePort
-
setHealthCheckNodePort
public void setHealthCheckNodePort(Integer healthCheckNodePort)
-
ipFamily
public IoK8sApiCoreV1ServiceSpec ipFamily(String ipFamily)
-
getIpFamily
@Nullable public String getIpFamily()
ipFamily specifies whether this Service has a preference for a particular IP family (e.g. IPv4 vs. IPv6). If a specific IP family is requested, the clusterIP field will be allocated from that family, if it is available in the cluster. If no IP family is requested, the cluster's primary IP family will be used. Other IP fields (loadBalancerIP, loadBalancerSourceRanges, externalIPs) and controllers which allocate external load-balancers should use the same IP family. Endpoints for this Service will be of this family. This field is immutable after creation. Assigning a ServiceIPFamily not available in the cluster (e.g. IPv6 in IPv4 only cluster) is an error condition and will fail during clusterIP assignment.- Returns:
- ipFamily
-
setIpFamily
public void setIpFamily(String ipFamily)
-
loadBalancerIP
public IoK8sApiCoreV1ServiceSpec loadBalancerIP(String loadBalancerIP)
-
getLoadBalancerIP
@Nullable public String getLoadBalancerIP()
Only applies to Service Type: LoadBalancer LoadBalancer will get created with the IP specified in this field. This feature depends on whether the underlying cloud-provider supports specifying the loadBalancerIP when a load balancer is created. This field will be ignored if the cloud-provider does not support the feature.- Returns:
- loadBalancerIP
-
setLoadBalancerIP
public void setLoadBalancerIP(String loadBalancerIP)
-
loadBalancerSourceRanges
public IoK8sApiCoreV1ServiceSpec loadBalancerSourceRanges(List<String> loadBalancerSourceRanges)
-
addLoadBalancerSourceRangesItem
public IoK8sApiCoreV1ServiceSpec addLoadBalancerSourceRangesItem(String loadBalancerSourceRangesItem)
-
getLoadBalancerSourceRanges
@Nullable public List<String> getLoadBalancerSourceRanges()
If specified and supported by the platform, this will restrict traffic through the cloud-provider load-balancer will be restricted to the specified client IPs. This field will be ignored if the cloud-provider does not support the feature.\" More info: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/- Returns:
- loadBalancerSourceRanges
-
setLoadBalancerSourceRanges
public void setLoadBalancerSourceRanges(List<String> loadBalancerSourceRanges)
-
ports
public IoK8sApiCoreV1ServiceSpec ports(List<IoK8sApiCoreV1ServicePort> ports)
-
addPortsItem
public IoK8sApiCoreV1ServiceSpec addPortsItem(IoK8sApiCoreV1ServicePort portsItem)
-
getPorts
@Nullable public List<IoK8sApiCoreV1ServicePort> getPorts()
The list of ports that are exposed by this service. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies- Returns:
- ports
-
setPorts
public void setPorts(List<IoK8sApiCoreV1ServicePort> ports)
-
publishNotReadyAddresses
public IoK8sApiCoreV1ServiceSpec publishNotReadyAddresses(Boolean publishNotReadyAddresses)
-
getPublishNotReadyAddresses
@Nullable public Boolean getPublishNotReadyAddresses()
publishNotReadyAddresses, when set to true, indicates that DNS implementations must publish the notReadyAddresses of subsets for the Endpoints associated with the Service. The default value is false. The primary use case for setting this field is to use a StatefulSet's Headless Service to propagate SRV records for its Pods without respect to their readiness for purpose of peer discovery.- Returns:
- publishNotReadyAddresses
-
setPublishNotReadyAddresses
public void setPublishNotReadyAddresses(Boolean publishNotReadyAddresses)
-
selector
public IoK8sApiCoreV1ServiceSpec selector(Map<String,String> selector)
-
putSelectorItem
public IoK8sApiCoreV1ServiceSpec putSelectorItem(String key, String selectorItem)
-
getSelector
@Nullable public Map<String,String> getSelector()
Route service traffic to pods with label keys and values matching this selector. If empty or not present, the service is assumed to have an external process managing its endpoints, which Kubernetes will not modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/- Returns:
- selector
-
sessionAffinity
public IoK8sApiCoreV1ServiceSpec sessionAffinity(String sessionAffinity)
-
getSessionAffinity
@Nullable public String getSessionAffinity()
Supports \"ClientIP\" and \"None\". Used to maintain session affinity. Enable client IP based session affinity. Must be ClientIP or None. Defaults to None. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies- Returns:
- sessionAffinity
-
setSessionAffinity
public void setSessionAffinity(String sessionAffinity)
-
sessionAffinityConfig
public IoK8sApiCoreV1ServiceSpec sessionAffinityConfig(IoK8sApiCoreV1SessionAffinityConfig sessionAffinityConfig)
-
getSessionAffinityConfig
@Nullable public IoK8sApiCoreV1SessionAffinityConfig getSessionAffinityConfig()
Get sessionAffinityConfig- Returns:
- sessionAffinityConfig
-
setSessionAffinityConfig
public void setSessionAffinityConfig(IoK8sApiCoreV1SessionAffinityConfig sessionAffinityConfig)
-
topologyKeys
public IoK8sApiCoreV1ServiceSpec topologyKeys(List<String> topologyKeys)
-
addTopologyKeysItem
public IoK8sApiCoreV1ServiceSpec addTopologyKeysItem(String topologyKeysItem)
-
getTopologyKeys
@Nullable public List<String> getTopologyKeys()
topologyKeys is a preference-order list of topology keys which implementations of services should use to preferentially sort endpoints when accessing this Service, it can not be used at the same time as externalTrafficPolicy=Local. Topology keys must be valid label keys and at most 16 keys may be specified. Endpoints are chosen based on the first topology key with available backends. If this field is specified and all entries have no backends that match the topology of the client, the service has no backends for that client and connections should fail. The special value \"*\" may be used to mean \"any topology\". This catch-all value, if used, only makes sense as the last value in the list. If this is not specified or empty, no topology constraints will be applied.- Returns:
- topologyKeys
-
type
public IoK8sApiCoreV1ServiceSpec type(String type)
-
getType
@Nullable public String getType()
type determines how the Service is exposed. Defaults to ClusterIP. Valid options are ExternalName, ClusterIP, NodePort, and LoadBalancer. \"ExternalName\" maps to the specified externalName. \"ClusterIP\" allocates a cluster-internal IP address for load-balancing to endpoints. Endpoints are determined by the selector or if that is not specified, by manual construction of an Endpoints object. If clusterIP is \"None\", no virtual IP is allocated and the endpoints are published as a set of endpoints rather than a stable IP. \"NodePort\" builds on ClusterIP and allocates a port on every node which routes to the clusterIP. \"LoadBalancer\" builds on NodePort and creates an external load-balancer (if supported in the current cloud) which routes to the clusterIP. More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types- Returns:
- type
-
setType
public void setType(String type)
-
-