newrelic_rpm 3.16.1.320 → 3.16.2.321
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG +9 -1
- data/lib/new_relic/agent/instrumentation/active_record_subscriber.rb +3 -1
- data/lib/new_relic/agent/transaction/abstract_segment.rb +9 -0
- data/lib/new_relic/version.rb +1 -1
- data/test/multiverse/suites/active_record/active_record_test.rb +9 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d5fbd063ff6696e5f6ca06468d904efd894895f0
|
4
|
+
data.tar.gz: ce04df3458e79da8fd0dcb30d5b5c5b9163013ca
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 728c1d9a90c3dacd41feb973c580fe65ac6be12a6373601fcd016ffe80deeb42c35ef48ebeda9db851a1e6016295ee86dfce599a2c79ef3eb7b4157a107ec88c
|
7
|
+
data.tar.gz: 7d16bb5da40a84b1ba4def5d9b7cafc82d65c0afe66b48d9b7ef6e37c1b1742c839e2b385d3ef7985ab72172c8ebb6966263837b0a29b37899a4b787ac8b78fe
|
data/CHANGELOG
CHANGED
@@ -1,6 +1,14 @@
|
|
1
1
|
# New Relic Ruby Agent Release Notes #
|
2
2
|
|
3
|
-
## v3.16.
|
3
|
+
## v3.16.2 ##
|
4
|
+
|
5
|
+
* Fix for "Unexpected frame in traced method stack" errors
|
6
|
+
|
7
|
+
Our ActiveRecord 4.x instrumentation could have generated "Unexpected frame in
|
8
|
+
traced method stack" errors when used outside of an active transaction (for
|
9
|
+
example, in custom background job handlers). This has been fixed.
|
10
|
+
|
11
|
+
## v3.16.1 ##
|
4
12
|
|
5
13
|
* Internal datastore instrumentation rewrites
|
6
14
|
|
@@ -97,7 +97,9 @@ module NewRelic
|
|
97
97
|
# See comment for start_segment as we continue to work around limitations of the
|
98
98
|
# current tracer in this method.
|
99
99
|
def finish
|
100
|
-
state.
|
100
|
+
if state.current_transaction
|
101
|
+
state.traced_method_stack.push_segment state, @segment
|
102
|
+
end
|
101
103
|
@segment.finish
|
102
104
|
end
|
103
105
|
|
@@ -46,6 +46,15 @@ module NewRelic
|
|
46
46
|
raise NotImplementedError, "Subclasses must implement record_metrics"
|
47
47
|
end
|
48
48
|
|
49
|
+
INSPECT_IGNORE = [:@transaction, :@transaction_state].freeze
|
50
|
+
|
51
|
+
def inspect
|
52
|
+
ivars = (instance_variables - INSPECT_IGNORE).inject([]) do |memo, var_name|
|
53
|
+
memo << "#{var_name}=#{instance_variable_get(var_name).inspect}"
|
54
|
+
end
|
55
|
+
sprintf('#<%s:0x%x %s>', self.class.name, object_id, ivars.join(', '))
|
56
|
+
end
|
57
|
+
|
49
58
|
private
|
50
59
|
|
51
60
|
# callback for subclasses to override
|
data/lib/new_relic/version.rb
CHANGED
@@ -571,6 +571,15 @@ class ActiveRecordInstrumentationTest < Minitest::Test
|
|
571
571
|
})
|
572
572
|
end
|
573
573
|
|
574
|
+
def test_segment_skips_traced_method_stack_outside_txn
|
575
|
+
state = NewRelic::Agent::TransactionState.tl_get
|
576
|
+
stack = state.traced_method_stack
|
577
|
+
stack.expects(:push_segment).never
|
578
|
+
|
579
|
+
Order.create(:name => 'bob')
|
580
|
+
end
|
581
|
+
|
582
|
+
|
574
583
|
## helpers
|
575
584
|
|
576
585
|
def adapter
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: newrelic_rpm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.16.
|
4
|
+
version: 3.16.2.321
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tim Krajcar
|
@@ -12,7 +12,7 @@ authors:
|
|
12
12
|
autorequire:
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
|
-
date: 2016-08-
|
15
|
+
date: 2016-08-22 00:00:00.000000000 Z
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|
18
18
|
name: rake
|