mirror of
https://github.com/elastic/logstash.git
synced 2025-04-24 06:37:19 -04:00
parent
5c919f2831
commit
d5b5f9a4fc
1 changed files with 3 additions and 3 deletions
|
@ -20,8 +20,8 @@ java_import 'org.logstash.instrument.reports.ProcessReport'
|
|||
module LogStash module Instrument module PeriodicPoller
|
||||
class JVM < Base
|
||||
class GarbageCollectorName
|
||||
YOUNG_GC_NAMES = Set.new(["Copy", "PS Scavenge", "ParNew", "G1 Young Generation", "scavenge"])
|
||||
OLD_GC_NAMES = Set.new(["MarkSweepCompact", "PS MarkSweep", "ConcurrentMarkSweep", "G1 Old Generation", "global"])
|
||||
YOUNG_GC_NAMES = Set.new(["Copy", "PS Scavenge", "ParNew", "G1 Young Generation", "scavenge", "GPGC New"])
|
||||
OLD_GC_NAMES = Set.new(["MarkSweepCompact", "PS MarkSweep", "ConcurrentMarkSweep", "G1 Old Generation", "global", "GPGC Old"])
|
||||
|
||||
YOUNG = :young
|
||||
OLD = :old
|
||||
|
@ -68,7 +68,7 @@ module LogStash module Instrument module PeriodicPoller
|
|||
logger.debug("collector name", :name => collector_name)
|
||||
name = GarbageCollectorName.get(collector_name)
|
||||
if name.nil?
|
||||
logger.error("Unknown garbage collector name", :name => name)
|
||||
logger.error("Unknown garbage collector name", :name => collector_name)
|
||||
else
|
||||
metric.gauge([:jvm, :gc, :collectors, name], :collection_count, collector.getCollectionCount())
|
||||
metric.gauge([:jvm, :gc, :collectors, name], :collection_time_in_millis, collector.getCollectionTime())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue