tunemygc 1.0.18 → 1.0.20

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: 2c2faef3f82c3891c957e4de799006540ec4b86c
4
- data.tar.gz: 5e12afc1345d92163f7d1ac2d805d8aef48570d0
3
+ metadata.gz: f2a137fcc751bdbe687ec275b922f67a3a666a44
4
+ data.tar.gz: ca258ed73bfe627031d4ccffac7457ad0deaab0d
5
5
  SHA512:
6
- metadata.gz: 31bb0d362295f2738b385e3b8e108da6ff95374d50c7c6a77a790e02ebaa1fb1210c3446b070a159e1957abdb4520517c0f02adaea01676594cde8f24ea99812
7
- data.tar.gz: d4750545d48d6d7e4ff556542f4c6e1d0521aebe14fa1318bc95916a6e341a772631765f30096290bc11511190faf28b93c1bcc838a512b0433bf67ce97794f0
6
+ metadata.gz: a901f3e56967e38228fd57d40d33f7db7a8cf143a06d8b4644df93d2f4aa2a15f3580c1499437dd25d9e895146afd100c336007f2c34f964033c69b40701f6fb
7
+ data.tar.gz: b7e615f3b6cc7d3ded86b68c53a66410215cff1584eaaa4e096f4a64dba7d78f35fb05f6dfa8ccf3056be51f51ffcf1dc66e747004e2479a2c64336b4a3827f6
data/lib/tunemygc.rb CHANGED
@@ -20,6 +20,7 @@ if ENV["RUBY_GC_TUNE"]
20
20
  else
21
21
  puts "[TuneMyGC] Rails not detected, loading minimal agent"
22
22
  require 'tunemygc/agent'
23
+ TuneMyGc.booted
23
24
  end
24
25
  else
25
26
  puts "[TuneMyGC] not enabled"
@@ -10,9 +10,8 @@ module TuneMyGc
10
10
 
11
11
  attr_accessor :logger, :interposer, :snapshotter
12
12
 
13
- # snapshot stages
14
13
  def booted
15
- snapshot(:BOOTED)
14
+ TuneMyGc.interposer.install
16
15
  end
17
16
 
18
17
  def processing_started
@@ -1,6 +1,5 @@
1
1
  # encoding: utf-8
2
2
 
3
- require 'active_support'
4
3
  require 'tunemygc/spies'
5
4
 
6
5
  module TuneMyGc
@@ -18,14 +17,18 @@ module TuneMyGc
18
17
  TuneMyGc.install_gc_tracepoint
19
18
  TuneMyGc.log "hooked: GC tracepoints"
20
19
  TuneMyGc.snapshot(:BOOTED)
21
-
22
20
  TuneMyGc.interposer.spy.install
23
21
  end
24
22
 
25
23
  def install
26
24
  return if @installed
27
25
  TuneMyGc.log "interposing"
28
- ActiveSupport.on_load(:after_initialize) do
26
+ if TuneMyGc.rails?
27
+ require 'active_support'
28
+ ActiveSupport.on_load(:after_initialize) do
29
+ TuneMyGc.interposer.on_initialized
30
+ end
31
+ else
29
32
  TuneMyGc.interposer.on_initialized
30
33
  end
31
34
  TuneMyGc.log "hooked: after_initialize"
@@ -1,5 +1,5 @@
1
1
  # encoding: utf-8
2
2
 
3
3
  module TuneMyGc
4
- VERSION = "1.0.18"
4
+ VERSION = "1.0.20"
5
5
  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.18
4
+ version: 1.0.20
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-18 00:00:00.000000000 Z
11
+ date: 2015-02-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport