scout_apm 1.6.6 → 1.6.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: eb70c9255d9b51e1691eb4f474a4630726754150
4
- data.tar.gz: 6e6f32ce2e18b3b86f8da4ee54343779db645e2b
3
+ metadata.gz: 51e6646411ef8e7e03434c2c4680a468fb1c5735
4
+ data.tar.gz: f79cd89522151be528c1076d5fc65b2abdd62f66
5
5
  SHA512:
6
- metadata.gz: 55ce37c278114185f6f80bfb0db10418f366f8a92693a27aaa9addbfa7f5d826fcb56655350fd8a15823997a3faf0880896fe5fd85ba172bc8f9dff136cd3bcb
7
- data.tar.gz: 8e2f769bb9b69b9cb000e4d8cf276ce6c6be73e3715494506f8be649e05c509436681ccc47eca8b85c0ce8702caaf215c102479f49629c80f8b02c4a791c9370
6
+ metadata.gz: b893c84366f77e64c74d8b84d7c4a20a625358d52bd6b600fefbf807fc35bf2aa8e27fc12c032bc4f4a23b76d713cb575ff0b521388c39ae5f728e94cb2d9717
7
+ data.tar.gz: 420ee003c01b6f2c7b7f0c7c15001f6acd501a7d6dcbaa47ced8e4f27dff5195c6e265975fdd625aaae16811cf75de6aafb98a9660ee28639c9494f0c4ac8405
@@ -1,3 +1,7 @@
1
+ # 1.6.7
2
+
3
+ * Mongoid bugfixes
4
+
1
5
  # 1.6.6
2
6
 
3
7
  * Bugfix related to DB detection
@@ -17,7 +17,7 @@ module ScoutApm
17
17
 
18
18
  # Mongoid versions that use Moped should instrument Moped.
19
19
  if defined?(::Mongoid) and !defined?(::Moped)
20
- ScoutApm::Agent.instance.logger.info "Instrumenting Mongoid"
20
+ ScoutApm::Agent.instance.logger.info "Instrumenting Mongoid 2.x"
21
21
 
22
22
  ### OLD (2.x) mongoids
23
23
  if defined?(::Mongoid::Collection)
@@ -33,6 +33,7 @@ module ScoutApm
33
33
 
34
34
  ### 5.x Mongoid
35
35
  if mongoid_v5? && defined?(::Mongoid::Contextual::Mongo)
36
+ ScoutApm::Agent.instance.logger.info "Instrumenting Mongoid 5.x"
36
37
  # All the public methods from Mongoid::Contextual::Mongo.
37
38
  # TODO: Geo and MapReduce support (?). They are in other Contextual::* classes
38
39
  methods = [
@@ -46,8 +47,8 @@ module ScoutApm
46
47
 
47
48
  methods.each do |method|
48
49
  if ::Mongoid::Contextual::Mongo.method_defined?(method)
49
- with_scout_instruments = %Q|
50
- def #{method}_with_scout_instruments(*args)
50
+ with_scout_instruments = %Q[
51
+ def #{method}_with_scout_instruments(*args, &block)
51
52
 
52
53
  req = ScoutApm::RequestManager.lookup
53
54
  *db, collection = view.collection.namespace.split(".")
@@ -60,7 +61,7 @@ module ScoutApm
60
61
 
61
62
  req.start_layer( layer )
62
63
  begin
63
- #{method}_without_scout_instruments
64
+ #{method}_without_scout_instruments(*args, &block)
64
65
  ensure
65
66
  req.stop_layer
66
67
  end
@@ -68,7 +69,7 @@ module ScoutApm
68
69
 
69
70
  alias_method :#{method}_without_scout_instruments, :#{method}
70
71
  alias_method :#{method}, :#{method}_with_scout_instruments
71
- |
72
+ ]
72
73
 
73
74
  ::Mongoid::Contextual::Mongo.class_eval(with_scout_instruments)
74
75
  end
@@ -1,4 +1,4 @@
1
1
  module ScoutApm
2
- VERSION = "1.6.6"
2
+ VERSION = "1.6.7"
3
3
  end
4
4
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scout_apm
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.6
4
+ version: 1.6.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Derek Haynes
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-07-14 00:00:00.000000000 Z
12
+ date: 2016-07-27 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: minitest