Class KubernetesProperties
Configuration class of the Hazelcast Discovery Plugin for Kubernetes.
For possible configuration properties please refer to the public constants of this class.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final PropertyDefinitionConfiguration key:expose-externallystatic final PropertyDefinitionConfiguration key:kubernetes-api-retriesstatic final PropertyDefinitionConfiguration key:api-tokenstatic final PropertyDefinitionConfiguration key:ca-certificateCA Authority certificate from Kubernetes Master, defaults to reading the certificate from the auto-injected file at:/var/run/secrets/kubernetes.io/serviceaccount/ca.crtstatic final PropertyDefinitionConfiguration key:kubernetes-masterstatic final StringConfiguration System Environment Prefix:hazelcast.kubernetes.static final PropertyDefinitionConfiguration key:namespacestatic final PropertyDefinitionConfiguration key:pod-label-namestatic final PropertyDefinitionConfiguration key:pod-label-valuestatic final PropertyDefinitionConfiguration key:resolve-not-ready-addressesstatic final PropertyDefinitionConfiguration key:service-dnsstatic final PropertyDefinitionConfiguration key:service-dns-timeoutstatic final PropertyDefinitionConfiguration key:service-label-namestatic final PropertyDefinitionConfiguration key:service-label-valuestatic final PropertyDefinitionConfiguration key:service-namestatic final PropertyDefinitionConfiguration key:service-per-pod-label-namestatic final PropertyDefinitionConfiguration key:service-per-pod-label-valuestatic final PropertyDefinitionConfiguration key:service-portstatic final PropertyDefinitionConfiguration key:use-node-name-as-external-address -
Method Summary
-
Field Details
-
KUBERNETES_SYSTEM_PREFIX
Configuration System Environment Prefix:
Defines the prefix for system environment variables and JVM command line parameters.hazelcast.kubernetes.
Defining or overriding properties as JVM parameters or using the system environment, those properties need to be prefixed to prevent collision on property names.
Example:SERVICE_DNSwill be:-Dhazelcast.kubernetes.service-dns=valueFor kubernetes and openshift there is a special rule where the environment variables are provided in C-identifier style, therefore the prefix is converted to uppercase and dots and dashed will be replaced with underscores:HAZELCAST_KUBERNETES_SERVICE_DNS=value- See Also:
-
SERVICE_DNS
Configuration key:
Defines the DNS service lookup domain. This is defined as something similar toservice-dnsmy-svc.my-namespace.svc.cluster.local.
For more information please refer to the official documentation of the Kubernetes DNS addon, here. -
SERVICE_DNS_TIMEOUT
Configuration key:
Defines the DNS service lookup timeout in seconds. Defaults to: 5 secs.service-dns-timeout -
SERVICE_NAME
Configuration key:
Defines the service name of the POD to lookup through the Service Discovery REST API of Kubernetes.service-name -
SERVICE_LABEL_NAME
Configuration key:
Defines the comma separated service labels to lookup through the Service Discovery REST API of Kubernetes.service-label-name -
SERVICE_LABEL_VALUE
Configuration key:
Defines the comma separated service label values to lookup through the Service Discovery REST API of Kubernetes.service-label-value -
NAMESPACE
Configuration key:
Defines the namespace of the application POD through the Service Discovery REST API of Kubernetes.namespace -
POD_LABEL_NAME
Configuration key:
Defines the comma separated pod labels to lookup through the Service Discovery REST API of Kubernetes.pod-label-name -
POD_LABEL_VALUE
Configuration key:
Defines the comma separated pod label values to lookup through the Service Discovery REST API of Kubernetes.pod-label-value -
EXPOSE_EXTERNALLY
Configuration key:
Specifies if Hazelcast should try to find its public addresses exposed with a single service. If not set, Hazelcast tries to automatically find public addresses, but fails silently. Ifexpose-externallytruefalse, Hazelcast crashes if it can't find its public address. Iffalse, Hazelcast does not even try to find its public address. -
SERVICE_PER_POD_LABEL_NAME
Configuration key:
Defines the label name of the service used to expose one Hazelcast pod (for the external client use case).service-per-pod-label-name -
SERVICE_PER_POD_LABEL_VALUE
Configuration key:
Defines the label value of the service used to expose one Hazelcast pod (for the external client use case).service-per-pod-label-value -
RESOLVE_NOT_READY_ADDRESSES
Configuration key:
Defines if not ready addresses should be evaluated to be discovered on startup.resolve-not-ready-addresses -
USE_NODE_NAME_AS_EXTERNAL_ADDRESS
Configuration key:
Defines if the node name should be used as external address, instead of looking up the external IP using theuse-node-name-as-external-address/nodesresource. Default is false. -
KUBERNETES_API_RETIRES
Configuration key:
Defines the number of retries to Kubernetes API. Defaults to: 3.kubernetes-api-retries -
KUBERNETES_MASTER_URL
Configuration key:
Defines an alternative address for the kubernetes master. Defaults to:kubernetes-masterhttps://kubernetes.default.svc -
KUBERNETES_API_TOKEN
Configuration key:
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:api-token/var/run/secrets/kubernetes.io/serviceaccount/token -
KUBERNETES_CA_CERTIFICATE
Configuration key:ca-certificateCA Authority certificate from Kubernetes Master, defaults to reading the certificate from the auto-injected file at:/var/run/secrets/kubernetes.io/serviceaccount/ca.crt -
SERVICE_PORT
Configuration key:
If specified with a value greater than 0, its value defines the endpoint port of the service (overriding the default).service-port
-