Class: NewRelic::Agent::StatsEngine::GCProfiler::RailsBench
- Inherits:
-
Profiler
- Object
- Profiler
- NewRelic::Agent::StatsEngine::GCProfiler::RailsBench
show all
- Defined in:
- lib/new_relic/agent/stats_engine/gc_profiler.rb
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Profiler
#capture, #initialize
Class Method Details
.enabled? ⇒ Boolean
61
62
63
|
# File 'lib/new_relic/agent/stats_engine/gc_profiler.rb', line 61
def self.enabled?
::GC.respond_to?(:time) && ::GC.respond_to?(:collections)
end
|
Instance Method Details
#call_count ⇒ Object
70
71
72
|
# File 'lib/new_relic/agent/stats_engine/gc_profiler.rb', line 70
def call_count
::GC.collections
end
|
#call_time ⇒ Object
66
67
68
|
# File 'lib/new_relic/agent/stats_engine/gc_profiler.rb', line 66
def call_time
::GC.time end
|
#reset ⇒ Object
74
75
76
|
# File 'lib/new_relic/agent/stats_engine/gc_profiler.rb', line 74
def reset
::GC.clear_stats
end
|