On Tue, 31 Aug 2021 08:42:58 GMT, Erik Gahlin <egah...@openjdk.org> wrote:

>> Markus Grönlund has updated the pull request incrementally with three 
>> additional commits since the last revision:
>> 
>>  - localize
>>  - cleanup
>>  - FinalizerStatistics
>
> test/jdk/jdk/jfr/event/runtime/TestFinalizerStatisticsEvent.java line 98:
> 
>> 96:               case TEST_CLASS_NAME: {
>> 97:                   
>> Asserts.assertTrue(event.getString("codeSource").startsWith("file://"));
>> 98:                   foundTestClassName = true;
> 
> Could we (sanity) check "objects" and "totalFinalzersRun" fields as well?

It's risky to do because of the non-deterministic nature of when the Finalizer 
thread runs (if at all). The best I could think of is to check if either field 
is 0 or more, but that becomes so weak it's not much of a sanity check.

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

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

Reply via email to