On Tue, 2 Feb 2021 04:09:24 GMT, Chris Plummer <[email protected]> wrote:
>> Hi all,
>>
>> com/sun/jdi/JdbOptions.java fails in our ci/cd when jfr is disabled.
>> It would be better to fix it.
>>
>> Thanks.
>> Best regards,
>> Jie
>
> test/jdk/com/sun/jdi/JdbOptions.java line 99:
>
>> 97: test("-connect",
>> 98:
>> "com.sun.jdi.CommandLineLaunch:vmexec=java,options=\"-client\"
>> \"-XX:+PrintVMOptions\""
>> 99: + " -XX:+IgnoreUnrecognizedVMOptions"
>
> You need to be careful when using `-xx:+IgnoreUnrecognizedVMOptions`, because
> it can result in not detecting typos in the option names, which could happen
> with this test in the future if any other mods are made. Other options here
> are to skip this part of the test if JFR is not present, or better yet don't
> make the test rely on JFR. I don't think there is a reason that it needs to.
> It seems other options could have been used for the testing. Perhaps
> @alexmenkov can comment on why it was done this way.
Thanks @plummercj for your review.
Let's wait for @alexmenkov 's comments.
Thanks.
-------------
PR: https://git.openjdk.java.net/jdk/pull/2346