Skip to content

Commit e194bcc

Browse files
committed
[hotfix] Remove any user-provided total Flink memory settings
1 parent e1d9291 commit e194bcc

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

Diff for: flink-autoscaler/src/main/java/org/apache/flink/autoscaler/tuning/MemoryTuning.java

+1
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,7 @@ public static ConfigChanges tuneTaskManagerMemory(
169169
// memory pools, there are no fractional variants for heap memory. Setting the absolute heap
170170
// memory options could cause invalid configuration states when users adapt the total amount
171171
// of memory. We also need to take care to remove any user-provided overrides for those.
172+
tuningConfig.addRemoval(TaskManagerOptions.TOTAL_FLINK_MEMORY);
172173
tuningConfig.addRemoval(TaskManagerOptions.TASK_HEAP_MEMORY);
173174
// Set default to zero because we already account for heap via task heap.
174175
tuningConfig.addOverride(TaskManagerOptions.FRAMEWORK_HEAP_MEMORY, MemorySize.ZERO);

Diff for: flink-autoscaler/src/test/java/org/apache/flink/autoscaler/tuning/MemoryTuningTest.java

+1
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@ jobVertex1, new ScalingSummary(50, 25, Map.of()),
124124

125125
assertThat(configChanges.getRemovals())
126126
.containsExactlyInAnyOrder(
127+
TaskManagerOptions.TOTAL_FLINK_MEMORY.key(),
127128
TaskManagerOptions.TASK_HEAP_MEMORY.key(),
128129
TaskManagerOptions.MANAGED_MEMORY_SIZE.key(),
129130
TaskManagerOptions.MANAGED_MEMORY_SIZE

0 commit comments

Comments
 (0)