RFR: 7201: JdkAttributes.OS_SWITCH_RATE does not work consistently across JFRs from different JDK versions.
Suchita Chaturvedi
schaturvedi at openjdk.java.net
Tue May 11 15:07:54 UTC 2021
On Tue, 11 May 2021 15:00:42 GMT, Marcus Hirt <hirt at openjdk.org> wrote:
>> This PR addresses the issue of switchRate attribute not accessible via core API when used for JFR generated with JDK 11 and above.
>>
>> Please review the change and provide your valuable comments.
>
> core/org.openjdk.jmc.flightrecorder/src/main/java/org/openjdk/jmc/flightrecorder/parser/synthetic/SyntheticAttributeExtension.java line 198:
>
>> 196:
>> 197: } else if (eventTypeId
>> 198: .equalsIgnoreCase("http://www.oracle.com/hotspot/jvm/os/processor/context_switch_rate")) {
>
> This line here:
> .equalsIgnoreCase("http://www.oracle.com/hotspot/jvm/os/processor/context_switch_rate")
Ok so it should be eventTypeId.equalsIgnoreCase(OracleJdkTypeIDsPre11.CONTEXT_SWITCH_RATE) ?
-------------
PR: https://git.openjdk.java.net/jmc/pull/246
More information about the jmc-dev
mailing list