Operator configuration

Specify default configurations for the Flink Operator.

You can specify default configuration for the Flink Operator that is shared between the operator itself and the Flink deployments.

The configuration files are mounted externally through ConfigMaps created during the Helm chart installation. Cloudera recommends reviewing and adjusting the configurations in the values.yaml file, if applicable, before deploying the Flink Operator in production environments.

To append to the default configuration, define the flink-conf.yaml key in the flink-kubernetes-operator.defaultConfiguration section of the Helm values.yaml file:

defaultConfiguration:
  create: true
  # Set append to false to replace configuration files
  append: true
  flink-conf.yaml: |+
    # Flink Config Overrides
    kubernetes.operator.metrics.reporter.slf4j.factory.class: org.apache.flink.metrics.slf4j.Slf4jReporterFactory
    kubernetes.operator.metrics.reporter.slf4j.interval: 5 MINUTE

    kubernetes.operator.reconcile.interval: 15 s
    kubernetes.operator.observer.progress-check.interval: 5 s

The list of Flink Operator configurations can be found in Specifying Operator Configuration.

Dynamic Operator Configuration

The Kubernetes Operator supports dynamic config changes through the ConfigMaps of the Operator. Dynamic operator configuration is enabled by default, and can be disabled by setting kubernetes.operator.dynamic.config.enabled to false. The time interval for checking dynamic config changes can be set by kubernetes.operator.dynamic.config.check.interval. The default value for the time interval is 5 minutes.

You can verify that the dynamic operator configuration is enabled through the deploy/flink-kubernetes-operator log has:
2022-05-28 13:08:29,222 o.a.f.k.o.c.FlinkConfigManager [INFO ] Enabled dynamic config updates, checking config changes every PT5M

To change configuration values dynamically the ConfigMap can be directly edited using kubectl patch or kubectl edit command.

To verify that the configuration value of kubernetes.operator.reconcile.interval is changed to 30 seconds, the deploy/flink-kubernetes-operator log should have the following information:

2022-05-28 13:08:30,115 o.a.f.k.o.c.FlinkConfigManager [INFO ] Updating default configuration to {kubernetes.operator.reconcile.interval=PT30S}