Method: LogStash::Util::ThreadDump#each
- Defined in:
- lib/logstash/util/thread_dump.rb
#each(&block) ⇒ Object
20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'lib/logstash/util/thread_dump.rb', line 20 def each(&block) i=0 dump.each do |hash| thread_name = hash["thread.name"] break if i >= top_count if ignore next if idle_thread?(thread_name, hash) end block.call(hash) i += 1 end end |