RFR: JDK-8273526: Extend the OSContainer API pids controller with pids.current [v3]

Ioi Lam iklam at openjdk.java.net
Tue Sep 14 17:28:03 UTC 2021


On Tue, 14 Sep 2021 16:36:24 GMT, Ioi Lam <iklam at openjdk.org> wrote:

>> Matthias Baesken has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Simplify coding following Severins advice
>
> test/hotspot/jtreg/containers/docker/TestPids.java line 97:
> 
>> 95:                 System.out.println("DEBUG: parts.length = " + parts.length);
>> 96:                 if (expectedValue.equals("no_value_expected")) {
>> 97:                     Asserts.assertEquals(parts.length, 2);
> 
> Is "no_value_expected" generated by Docker? I searched the entire HotSpot source code and couldn't find it. I also couldn't find "WARNING: Your kernel does not support pids limit capabilities". 
> 
> To make it easier to understand this test, I would suggest grouping all messages that were generated outside of HotSpot into something like:
> 
> 
> // These messages are generated by Docker
> static final String warning_kernel_no_pids_support = "WARNING: Your kernel does not support pids limit capabilities";
> static final String no_value_expected = "no_value_expected";

Oh, I misunderstood the test. "no_value_expected" was passed in from `testPids()` in this file, but that's confusing because you are expecting an integer value. Maybe it should be "any_integer"?

-------------

PR: https://git.openjdk.java.net/jdk/pull/5437


More information about the core-libs-dev mailing list