tillrohrmann commented on a change in pull request #12520:
URL: https://github.com/apache/flink/pull/12520#discussion_r436762242



##########
File path: 
flink-runtime/src/test/java/org/apache/flink/runtime/util/config/memory/ProcessMemoryUtilsTestBase.java
##########
@@ -125,6 +125,25 @@ public void 
testExceptionShouldContainRequiredConfigOptions() {
                }
        }
 
+       @Test
+       public void testDerivedTotalProcessMemoryGreaterThanConfiguredFailure() 
{
+               MemorySize totalFlinkMemorySize = MemorySize.parse("150m");
+               MemorySize jvmMetaspaceSize = MemorySize.parse("100m");
+               MemorySize totalProcessMemorySize = MemorySize.parse("200m");
+
+               Configuration conf = new Configuration();
+               conf.set(options.getJvmOptions().getJvmMetaspaceOption(), 
jvmMetaspaceSize);
+               conf.set(options.getTotalProcessMemoryOption(), 
totalProcessMemorySize);
+
+               // Total Flink memory + JVM Metaspace > Total Process Memory 
(no space for JVM overhead)
+
+               configWithFineGrainedOptions(conf, totalFlinkMemorySize);
+               validateFail(conf);
+
+               conf.set(options.getTotalProcessMemoryOption(), 
totalProcessMemorySize);
+               validateFail(conf);

Review comment:
       I would split this test case into two test cases.




----------------------------------------------------------------
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]


Reply via email to