tunemygc 1.0.3 → 1.0.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 41abc48ffc1562a193e97168a0facaa7666be2f1
4
- data.tar.gz: d1c8a2926de499ec7570b39fa488658ed25ea937
3
+ metadata.gz: c057ffb98292fe308fdbb32de479b706385a90cb
4
+ data.tar.gz: 31966bc7b7a03be74202a7e53d500d328aeceb0b
5
5
  SHA512:
6
- metadata.gz: 0f5e541a864122230c090f8c33a1f8f08db17ee376f2f4cda23af1c67c7e3c529f16ed5d9337731299bc8261f88e4ce1cce1e5d5d832676eeeecaae805364215
7
- data.tar.gz: 85c5077715cd14909ea3bec3e111767580f9c4804706719010a8ce2455984956531e33652aa4d4e3eaa36cc5c5439e7d37b0788a9381ea292f169b3b134219bd
6
+ metadata.gz: a34abf695d7403acb0608953897816438b9e54985928f1711e05ca887ebdb27c7936e8d060dd70418eff0fa53ccebfb8fcdf83fa1ad712f6965f835cf1a7b26c
7
+ data.tar.gz: b68ddd00fd18ad710280d1d062d8f59265d528ae49a2a477818de839b759ae50270ebbd6102cd92cc3dd2044c20f77efbe5813a9be36bd45dd001d61e1ff1bbf
@@ -5,7 +5,7 @@ require 'thread'
5
5
  module TuneMyGc
6
6
  class Snapshotter
7
7
  UNITS_OF_WORK = /REQUEST_PROCESSING_STARTED|REQUEST_PROCESSING_ENDED/
8
- MAX_SAMPLES = 1000
8
+ MAX_SAMPLES = (ENV['RUBY_GC_MAX_SAMPLES'] ? Integer(ENV['RUBY_GC_MAX_SAMPLES']) : 2000)
9
9
 
10
10
  attr_reader :buffer
11
11
  attr_accessor :unit_of_work
@@ -1,5 +1,5 @@
1
1
  # encoding: utf-8
2
2
 
3
3
  module TuneMyGc
4
- VERSION = "1.0.3"
4
+ VERSION = "1.0.4"
5
5
  end
@@ -25,17 +25,17 @@ class TestSnapshotter < TuneMyGcTestCase
25
25
 
26
26
  def test_max_samples
27
27
  snapshots = TuneMyGc::Snapshotter.new
28
- 1000.times do |i|
28
+ 2000.times do |i|
29
29
  snapshots.take(:MAX)
30
30
  end
31
- assert_equal 1000, snapshots.size
31
+ assert_equal 2000, snapshots.size
32
32
  out, err = capture_io do
33
33
  TuneMyGc.logger = Logger.new($stdout)
34
34
  snapshots.take(:MORE)
35
35
  snapshots.take(:ANOTHER)
36
36
  end
37
37
  assert_match(/Discarding snapshot/, out)
38
- assert_equal 1000, snapshots.size
38
+ assert_equal 2000, snapshots.size
39
39
  snapshots.clear
40
40
  end
41
41
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tunemygc
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.3
4
+ version: 1.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bear Metal
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-02-03 00:00:00.000000000 Z
11
+ date: 2015-02-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport