- java.lang.Object
-
- com.microsoft.gctoolkit.parser.GCLogParser
-
- All Implemented Interfaces:
ChannelListener<String>,DataSourceChannelListener,DataSourceParser,GenericTokens,PreUnifiedTokens,SharedPatterns
- Direct Known Subclasses:
PreUnifiedGCLogParser,ShenandoahParser,UnifiedG1GCParser,UnifiedGenerationalParser,UnifiedJVMEventParser,UnifiedSurvivorMemoryPoolParser,ZGCParser
public abstract class GCLogParser extends Object implements DataSourceParser, SharedPatterns
-
-
Field Summary
Fields Modifier and Type Field Description protected Diarydiarystatic StringEND_OF_DATA_SENTINELstatic GCParseRuleGCID_COUNTER-
Fields inherited from interface com.microsoft.gctoolkit.parser.GenericTokens
BEFORE_AFTER_CONFIGURED, BEFORE_AFTER_CONFIGURED_PAUSE, BEFORE_CONFIGURED_AFTER_CONFIGURED, BYTES, CHURN, CONCURRENT_TIME, COUNTER, CPU_SUMMARY, DATE, DECIMAL_POINT, DURATION_MS, GC_CAUSE, HEX, INT, INTEGER, MEMORY_SIZE, META_RECORD, OCCUPANCY_CONFIGURED, OCCUPANCY_CONFIGURED_PAUSE, PAUSE_TIME, PERCENTAGE, REAL_NUMBER, REAL_VALUE, SAFE_POINT_CAUSE, TIME, UNITS
-
Fields inherited from interface com.microsoft.gctoolkit.parser.PreUnifiedTokens
CLASSPACE_FINAL, CPU_BREAKDOWN, DATE_STAMP, DATE_TIMESTAMP, DATE_TIMESTAMP_RECORD, FINAL_REFERENCE, FRACTIONAL_BEFORE_AFTER_CONFIGURED, FRACTIONAL_MEMORY_SIZE, FULL_GC_PREFIX, GC_PREFIX, JNI_REFERENCE, JNI_REFERENCE_PROCESSING, MEMORY_ADDRESS, MEMORY_POOL_BOUNDS, META_PERM_MEMORY_SUMMARY, METASPACE_FINAL, MS_TIME_STAMP, PERM_RECORD, PHANTOM_REFERENCE, PHANTOM_REFERENCE_PROCESSING, PLAB, PLAB_RECORD, PRECLEAN_REFERENCE_PROCESSING, PRECLEAN_REFERENCE_RECORDS, REFERENCE_PROCESSING_BLOCK, REFERENCE_RECORDS, SOFT_REFERENCE, TIMESTAMP, USED_CAPACITY_COMMITTED_RESERVED, WEAK_REFERENCE
-
Fields inherited from interface com.microsoft.gctoolkit.parser.SharedPatterns
BEFORE_AFTER_CONFIGURED_PAUSE_RULE, CLASS_UNLOADING, CLASS_UNLOADING_BLOCK, MEMORY_SUMMARY_RULE, META_SPACE_RECORD, OCCUPANCY_CONFIGURED_RULE, PERM_SPACE_RECORD, STRING_AND_SYMBOL_SCRUB, STRING_AND_SYMBOL_SCRUB_BLOCK, STRING_TABLE_SCRUB, STRING_TABLE_SCRUB_BLOCK, SYMBOL_TABLE_SCRUB, SYMBOL_TABLE_SCRUB_BLOCK, TENURING_DETAILS, WEAK_REF, WEAK_REF_BLOCK
-
-
Constructor Summary
Constructors Constructor Description GCLogParser()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected voidadvanceClock(DateTimeStamp now)The assumption is, this method will manage the global clock and thus should never be over riddenChannelNamechannel()voiddiary(Diary diary)DateTimeStampgetClock()abstract StringgetName()protected abstract voidprocess(String trace)voidpublish(ChannelName channel, JVMEvent event)The clock is advanced to the time at the end of the event.voidpublishTo(JVMEventChannel channel)voidreceive(String trace)voidsetClock(DateTimeStamp newValue)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.microsoft.gctoolkit.message.DataSourceParser
accepts, eventsProduced
-
-
-
-
Field Detail
-
END_OF_DATA_SENTINEL
public static final String END_OF_DATA_SENTINEL
- See Also:
- Constant Field Values
-
GCID_COUNTER
public static final GCParseRule GCID_COUNTER
-
diary
protected Diary diary
-
-
Method Detail
-
diary
public void diary(Diary diary)
- Specified by:
diaryin interfaceDataSourceParser
-
getClock
public DateTimeStamp getClock()
-
setClock
public void setClock(DateTimeStamp newValue)
-
getName
public abstract String getName()
-
process
protected abstract void process(String trace)
-
advanceClock
protected final void advanceClock(DateTimeStamp now)
The assumption is, this method will manage the global clock and thus should never be over ridden- Parameters:
now- - DateTimeStamp from the current GC log record
-
publish
public void publish(ChannelName channel, JVMEvent event)
The clock is advanced to the time at the end of the event. The times reported in the GCLog file are "noisy" at best. This hyperactives the clock rollback detection which doesn't allow for slop. To minimize this, the clock only records when a time stamp is presented and isn't advanced to the end of the event except in the case of EOF where the time of JVM termination has not been recorded. In this case, JVMTermination time should advanced to after the previous event has ended.- Parameters:
channel-event-
-
receive
public void receive(String trace)
- Specified by:
receivein interfaceChannelListener<String>
-
publishTo
public void publishTo(JVMEventChannel channel)
- Specified by:
publishToin interfaceDataSourceParser
-
channel
public ChannelName channel()
- Specified by:
channelin interfaceChannelListener<String>
-
-