JMC-5895 - JFR in JDK 11 changed event paths from 'com.oracle.jdk' to 'jdk', and type paths from 'com.oracle.jfr.types' to 'jdk.types'

Sharath Ballal sharath.ballal at oracle.com
Mon Jul 16 06:23:38 UTC 2018


Thanks Marcus, I have done the changes.

Thanks,
Sharath


-----Original Message-----
From: Marcus Hirt 
Sent: Sunday, July 15, 2018 12:29 AM
To: Sharath Ballal; jmc-dev at openjdk.java.net
Subject: Re: JMC-5895 - JFR in JDK 11 changed event paths from 'com.oracle.jdk' to 'jdk', and type paths from 'com.oracle.jfr.types' to 'jdk.types'

Hi Sharath,

Some minor nits:

In SyntheticAttributeExtension.java:
+                 eventTypeId = JdkTypeIDsPreJdk11.translate(eventTypeId);
                  if (REC_SETTING_EVENT_ID_ATTRIBUTE.getIdentifier().equals(fieldId)
                                  && JdkTypeIDs.RECORDING_SETTING.equals(eventTypeId)) {
                          return JfrInternalConstants.TYPE_IDENTIFIER_VALUE_INTERPRETATION;
                  }

The translated eventTypeId is only used once, instead of redefining the parameter, please consider just translating the eventTypeId where it is used: 
                  if (REC_SETTING_EVENT_ID_ATTRIBUTE.getIdentifier().equals(fieldId)
                                  && JdkTypeIDs.RECORDING_SETTING.equals(JdkTypeIDsPreJdk11.translate(eventTypeId))) {
                          return JfrInternalConstants.TYPE_IDENTIFIER_VALUE_INTERPRETATION;
                  }

[Sharath Ballal] Done.

Indentation problem in needTransform in JdkTypeIDsPreJdk11:

 211         /**
 212          * Determine if a typeId needs to be transformed into a JDK 11 type id.
 213          *
 214          * @param typeId
 215          *            type id
 216          * @return true if transformation is needed, false otherwise.
 217          */
 218         public static boolean needTransform(String typeId) {
 219                 if (typeId.startsWith(PREFIX)) {
 220             return false;
 221         }
 222                 return typeId.startsWith(EVENT_ID_ROOT) || typeId.startsWith(PREFIX_9_10) ;
 223         }
 224

[Sharath Ballal] Done

Kind regards,
Marcus

On 2018-07-14, 07:02, "jmc-dev on behalf of Sharath Ballal" <jmc-dev-bounces at openjdk.java.net on behalf of sharath.ballal at oracle.com> wrote:

    The fix has undergone changes from last time as 'mvn verify' was failing.  The code changes now include: 
    
    1.      Changes to the V1 parser to use the SettingsTransformer for JDK 9 & 10 events.
    
    2.      Changes to some of the tests and their baseline files.
    
     
    
    Testing done:
    
    mvn verify passes.
    
    JDK 7/8/9/10 - Recording, loading and automated analysis works.  Verified that  scores of the automated analysis doesn't change from earlier.
    
    JDK 11 - Recording, loading and automated analysis works.  
    
     
    
    Latest webrev at : http://cr.openjdk.java.net/~sballal/JMC-5895/webrev.03/ 
    
    Kindly review the fix.
    
     
    
    Thanks,
    
    Sharath
    
     
    
     
    
    From: Sharath Ballal [mailto:sharath.ballal at oracle.com] 
    Sent: Friday, June 08, 2018 3:03 PM
    To: 'jmc-dev at openjdk.java.net'
    Subject: RFR: JMC-5895 - JFR in JDK 11 changed event paths from 'com.oracle.jdk' to 'jdk', and type paths from 'com.oracle.jfr.types' to 'jdk.types'
    
     
    
    Hello,
    
     
    
    Pls review fix for the following P1 issue:
    
     
    
    ID: https://bugs.openjdk.java.net/browse/JMC-5895 
    
    Webrev: http://cr.openjdk.java.net/~sballal/JMC-5895/webrev.00/ 
    
     
    
    Thanks,
    
    Sharath
    
     
    
     
    
    




More information about the jmc-dev mailing list