8242593: JFR: EventFactory does not scale well past unique 1000 event
    Erik Gahlin 
    erik.gahlin at oracle.com
       
    Sat Jun 20 16:07:44 UTC 2020
    
    
  
Hi,
Could I have review of a fix that prevents metadata to be written to 
native every time a new event is registered.
This means there is small chance that the JVM will not be able to write 
the most recent metadata if a crash occurs and an emergency recording is 
created. This will not impact ordinary recordings or event streaming, 
since stale metadata is written out before a segment or chunk is complete
For more details, see:
https://mail.openjdk.java.net/pipermail/jmc-dev/2020-June/002279.html
If the parser finds an event that lacks metadata, it will just skip that 
event. This will only occur if the JVM crashes within 1 second after new 
Java event is registered.
I did a small experiment and the time it takes to register 50 events now 
drops from 350 ms to 50 ms.
I also updated the 'jfr summary command', so it prints the event id if 
the metadata is missing. This makes it possible to verify that an event 
missing due to lack of metadata and not a configuration issue etc.
Bug:
https://bugs.openjdk.java.net/browse/JDK-8242593
Webrev:
http://cr.openjdk.java.net/~egahlin/8242593/
Testing: jdk/jdk/jfr
Thanks
Erik
    
    
More information about the hotspot-jfr-dev
mailing list