Currently If the following configuration is configured in flink-conf.yaml:
and the following configuration is configured via TableConfig:
Then users submit the job via CliFrontend, the configuration set via TableConfig will not take effect.
Intuitively, it should be that user specified configuration via TableConfig(has higher priority) and the configuration specified via flink-conf.yaml together determines the configuration of a job. However, it doesn't hold in all cases.
The root cause is that only the configuration specified in TableConfig in passed to StreamExecutionEnvironment during translate to plan. For the above case, as state.backend is not specified in TableConfig and so the configuration state.backend.rocksdb.memory.fixed-per-slot will not take effect. Please note that in above example, the state backend actually used will be RocksDB without the configuration state.backend.rocksdb.memory.fixed-per-slot and taskmanager.memory.task.off-heap.size.