Class HazelcastKubernetesDiscoveryProperties

java.lang.Object
org.apereo.cas.configuration.model.support.hazelcast.discovery.HazelcastKubernetesDiscoveryProperties
All Implemented Interfaces:
Serializable

@RequiresModule(name="cas-server-support-hazelcast-discovery-kubernetes") public class HazelcastKubernetesDiscoveryProperties extends Object implements Serializable
Since:
5.3.0
See Also:
  • Constructor Details

    • HazelcastKubernetesDiscoveryProperties

      public HazelcastKubernetesDiscoveryProperties()
  • Method Details

    • getServiceDns

      public String getServiceDns()
      Defines the DNS service lookup domain. This is defined as something similar to my-svc.my-namespace.svc.cluster.local.
    • getServiceDnsTimeout

      public int getServiceDnsTimeout()
      Defines the DNS service lookup timeout in seconds. Defaults to 5 secs.
    • getServiceName

      public String getServiceName()
      Defines the service name of the POD to lookup through the Service Discovery REST API of Kubernetes.
    • getServiceLabelName

      public String getServiceLabelName()
      Defines the service label to lookup through the Service Discovery REST API of Kubernetes.
    • getServiceLabelValue

      public String getServiceLabelValue()
      Defines the service label value to lookup through the Service Discovery REST API of Kubernetes.
    • getNamespace

      public String getNamespace()
      Defines the namespace of the application POD through the Service Discovery REST API of Kubernetes.
    • isResolveNotReadyAddresses

      public boolean isResolveNotReadyAddresses()
      Defines if not ready addresses should be evaluated to be discovered on startup.
    • getKubernetesMaster

      public String getKubernetesMaster()
      Defines an alternative address for the kubernetes master. Defaults to: https://kubernetes.default.svc
    • getApiToken

      public String getApiToken()
      Defines an oauth token for the kubernetes client to access the kubernetes REST API. Defaults to reading the token from the auto-injected file at: /var/run/secrets/kubernetes.io/serviceaccount/token.
    • getPodLabelName

      public String getPodLabelName()
      Defines the pod label to lookup through the Service Discovery REST API of Kubernetes.
    • getPodLabelValue

      public String getPodLabelValue()
      Defines the pod label value to lookup through the Service Discovery REST API of Kubernetes.
    • isUseNodeNameAsExternalAddress

      public boolean isUseNodeNameAsExternalAddress()
      Defines if the node name should be used as external address, instead of looking up the external IP using the /nodes resource. Default is false.
    • getApiRetries

      public int getApiRetries()
      Defines the number of retries to Kubernetes API. Defaults to: 3.
    • getCaCertificate

      public String getCaCertificate()
      CA Authority certificate from Kubernetes Master. Defaults to reading the certificate from the auto-injected file at: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt.
    • getServicePort

      public int getServicePort()
      If specified with a value greater than 0, its value defines the endpoint port of the service (overriding the default).
    • setServiceDns

      public HazelcastKubernetesDiscoveryProperties setServiceDns(String serviceDns)
      Defines the DNS service lookup domain. This is defined as something similar to my-svc.my-namespace.svc.cluster.local.
      Returns:
      this.
    • setServiceDnsTimeout

      public HazelcastKubernetesDiscoveryProperties setServiceDnsTimeout(int serviceDnsTimeout)
      Defines the DNS service lookup timeout in seconds. Defaults to 5 secs.
      Returns:
      this.
    • setServiceName

      public HazelcastKubernetesDiscoveryProperties setServiceName(String serviceName)
      Defines the service name of the POD to lookup through the Service Discovery REST API of Kubernetes.
      Returns:
      this.
    • setServiceLabelName

      public HazelcastKubernetesDiscoveryProperties setServiceLabelName(String serviceLabelName)
      Defines the service label to lookup through the Service Discovery REST API of Kubernetes.
      Returns:
      this.
    • setServiceLabelValue

      public HazelcastKubernetesDiscoveryProperties setServiceLabelValue(String serviceLabelValue)
      Defines the service label value to lookup through the Service Discovery REST API of Kubernetes.
      Returns:
      this.
    • setNamespace

      public HazelcastKubernetesDiscoveryProperties setNamespace(String namespace)
      Defines the namespace of the application POD through the Service Discovery REST API of Kubernetes.
      Returns:
      this.
    • setResolveNotReadyAddresses

      public HazelcastKubernetesDiscoveryProperties setResolveNotReadyAddresses(boolean resolveNotReadyAddresses)
      Defines if not ready addresses should be evaluated to be discovered on startup.
      Returns:
      this.
    • setKubernetesMaster

      public HazelcastKubernetesDiscoveryProperties setKubernetesMaster(String kubernetesMaster)
      Defines an alternative address for the kubernetes master. Defaults to: https://kubernetes.default.svc
      Returns:
      this.
    • setApiToken

      public HazelcastKubernetesDiscoveryProperties setApiToken(String apiToken)
      Defines an oauth token for the kubernetes client to access the kubernetes REST API. Defaults to reading the token from the auto-injected file at: /var/run/secrets/kubernetes.io/serviceaccount/token.
      Returns:
      this.
    • setPodLabelName

      public HazelcastKubernetesDiscoveryProperties setPodLabelName(String podLabelName)
      Defines the pod label to lookup through the Service Discovery REST API of Kubernetes.
      Returns:
      this.
    • setPodLabelValue

      public HazelcastKubernetesDiscoveryProperties setPodLabelValue(String podLabelValue)
      Defines the pod label value to lookup through the Service Discovery REST API of Kubernetes.
      Returns:
      this.
    • setUseNodeNameAsExternalAddress

      public HazelcastKubernetesDiscoveryProperties setUseNodeNameAsExternalAddress(boolean useNodeNameAsExternalAddress)
      Defines if the node name should be used as external address, instead of looking up the external IP using the /nodes resource. Default is false.
      Returns:
      this.
    • setApiRetries

      public HazelcastKubernetesDiscoveryProperties setApiRetries(int apiRetries)
      Defines the number of retries to Kubernetes API. Defaults to: 3.
      Returns:
      this.
    • setCaCertificate

      public HazelcastKubernetesDiscoveryProperties setCaCertificate(String caCertificate)
      CA Authority certificate from Kubernetes Master. Defaults to reading the certificate from the auto-injected file at: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt.
      Returns:
      this.
    • setServicePort

      public HazelcastKubernetesDiscoveryProperties setServicePort(int servicePort)
      If specified with a value greater than 0, its value defines the endpoint port of the service (overriding the default).
      Returns:
      this.