gyfora commented on code in PR #670: URL: https://github.com/apache/flink-kubernetes-operator/pull/670#discussion_r1325961310
########## flink-kubernetes-operator/src/main/java/org/apache/flink/kubernetes/operator/config/FlinkConfigBuilder.java: ########## @@ -420,13 +421,24 @@ private void setResource(Resource resource, Configuration effectiveConfig, boole ? JobManagerOptions.TOTAL_PROCESS_MEMORY : TaskManagerOptions.TOTAL_PROCESS_MEMORY; if (resource.getMemory() != null) { - effectiveConfig.setString(memoryConfigOption.key(), resource.getMemory()); + effectiveConfig.setString( + memoryConfigOption.key(), parseResourceMemoryString(resource.getMemory())); } configureCpu(resource, effectiveConfig, isJM); } } + // Using the K8s units specification for the JM and TM memory settings + private String parseResourceMemoryString(String memory) { + try { + return MemorySize.parse(memory).toString(); Review Comment: Even if Flink memoryutils interpret the decimal bytes incorrectly, we should not silently change the interpretation as it may cause failure in currently deployed prod jobs. We can fix this when we change "major version" ie bump the crd to v1. For now I think it is fine to interpret the current configs as before (even if technically incorrect at times) and open a follow up JIRA to fix this for v1. Wdyt? -- 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. To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org