azagrebin commented on a change in pull request #9105: 
[FLINK-13241][Yarn/Mesos] Fix Yarn/MesosResourceManager setting managed memory 
size into wrong configuration instance.
URL: https://github.com/apache/flink/pull/9105#discussion_r304983621
 
 

 ##########
 File path: 
flink-runtime/src/main/java/org/apache/flink/runtime/resourcemanager/ResourceManager.java
 ##########
 @@ -185,6 +199,10 @@ public ResourceManager(
                this.jmResourceIdRegistrations = new HashMap<>(4);
                this.taskExecutors = new HashMap<>(8);
                this.taskExecutorGatewayFutures = new HashMap<>(8);
+
+               this.defaultTaskManagerMemoryMB = 
ConfigurationUtils.getTaskManagerHeapMemory(flinkConfig).getMebiBytes();
+               this.numberOfTaskSlots = 
flinkConfig.getInteger(TaskManagerOptions.NUM_TASK_SLOTS);
+               this.slotsPerWorker = 
updateTaskManagerConfigAndCreateWorkerSlotProfiles(this.flinkConfig, 
defaultTaskManagerMemoryMB, numberOfTaskSlots);
 
 Review comment:
   Should this also happen in `StandaloneResourceManager`?
   It just looks as if this change was kept out of `StandaloneResourceManager` 
on purpose or there was another reason not to do it like this before?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to