newrelic_rpm 3.7.1.180 → 3.7.1.182
Sign up to get free protection for your applications and to get access to all the features.
- data.tar.gz.sig +0 -0
- data/.travis.yml +1 -0
- data/CHANGELOG +6 -0
- data/lib/new_relic/agent/instrumentation/mongo.rb +3 -1
- data/lib/new_relic/agent/supported_versions.rb +1 -2
- data/test/environments/rails21/Gemfile +0 -1
- data/test/environments/rails22/Gemfile +0 -1
- data/test/multiverse/suites/mongo/mongo_instrumentation_test.rb +10 -3
- metadata +6 -3
- metadata.gz.sig +0 -0
data.tar.gz.sig
CHANGED
Binary file
|
data/.travis.yml
CHANGED
data/CHANGELOG
CHANGED
@@ -27,6 +27,12 @@
|
|
27
27
|
outgoing Net::HTTP requests. This has been corrected, and reported HTTP
|
28
28
|
timings should now be more accurate.
|
29
29
|
|
30
|
+
* Fix for Mongo ensure_index instrumentation (3.7.1.182)
|
31
|
+
|
32
|
+
The Mongo instrumentation for ensure_index in 3.7.1.180 was not properly
|
33
|
+
calling through to the uninstrumented version of this method. This has been
|
34
|
+
fixed in 3.7.1.182. Thanks to Yuki Miyauchi for the fix!
|
35
|
+
|
30
36
|
## v3.7.0 ##
|
31
37
|
|
32
38
|
* Official Rubinius support (for Rubinius >= 2.2.1)
|
@@ -117,12 +117,14 @@ DependencyDetection.defer do
|
|
117
117
|
transaction_state.push_traced(false)
|
118
118
|
|
119
119
|
begin
|
120
|
-
result =
|
120
|
+
result = ensure_index_without_new_relic_trace(spec, opts, &block)
|
121
121
|
ensure
|
122
122
|
transaction_state.pop_traced
|
123
123
|
end
|
124
124
|
|
125
|
+
spec = spec.is_a?(Array) ? Hash[spec] : spec.dup
|
125
126
|
spec[:operation] = :ensureIndex
|
127
|
+
|
126
128
|
statement = NewRelic::Agent::Datastores::Mongo::StatementFormatter.format(spec)
|
127
129
|
if statement
|
128
130
|
NewRelic::Agent.instance.transaction_sampler.notice_nosql_statement(statement, (Time.now - t0).to_f)
|
@@ -11,9 +11,8 @@ module NewRelic
|
|
11
11
|
{
|
12
12
|
:type => :ruby,
|
13
13
|
:name => "MRI",
|
14
|
-
:supported => ["1.8.7", "1.9.2", "1.9.3", "2.0.0"],
|
14
|
+
:supported => ["1.8.7", "1.9.2", "1.9.3", "2.0.0", "2.1.0"],
|
15
15
|
:deprecated => ["1.8.6"],
|
16
|
-
:experimental=> [">= 2.1.0"],
|
17
16
|
:url => "https://www.ruby-lang.org",
|
18
17
|
:feed => "https://www.ruby-lang.org/en/feeds/news.rss",
|
19
18
|
:notes => [
|
@@ -170,7 +170,7 @@ if NewRelic::Agent::Datastores::Mongo.is_supported_version?
|
|
170
170
|
end
|
171
171
|
|
172
172
|
def test_records_metrics_for_ensure_index
|
173
|
-
@collection.ensure_index(
|
173
|
+
@collection.ensure_index([[unique_field_name, Mongo::ASCENDING]])
|
174
174
|
|
175
175
|
metrics = build_test_metrics(:ensureIndex)
|
176
176
|
expected = metrics_with_attributes(metrics, { :call_count => 1 })
|
@@ -179,11 +179,18 @@ if NewRelic::Agent::Datastores::Mongo.is_supported_version?
|
|
179
179
|
end
|
180
180
|
|
181
181
|
def test_ensure_index_does_not_record_insert
|
182
|
-
@collection.ensure_index(
|
182
|
+
@collection.ensure_index([[unique_field_name, Mongo::ASCENDING]])
|
183
183
|
|
184
184
|
assert_metrics_not_recorded(['Datastore/operation/MongoDB/insert'])
|
185
185
|
end
|
186
186
|
|
187
|
+
def test_ensure_index_does_call_ensure_index
|
188
|
+
options = [[unique_field_name, Mongo::ASCENDING]]
|
189
|
+
|
190
|
+
@collection.expects(:ensure_index_without_new_relic_trace).with(options, any_parameters).once
|
191
|
+
@collection.ensure_index(options)
|
192
|
+
end
|
193
|
+
|
187
194
|
def test_records_metrics_for_drop_index
|
188
195
|
name = @collection.create_index([[unique_field_name, Mongo::ASCENDING]])
|
189
196
|
NewRelic::Agent.drop_buffered_data
|
@@ -315,7 +322,7 @@ if NewRelic::Agent::Datastores::Mongo.is_supported_version?
|
|
315
322
|
segment = nil
|
316
323
|
|
317
324
|
in_transaction do
|
318
|
-
@collection.ensure_index(
|
325
|
+
@collection.ensure_index([[unique_field_name, Mongo::ASCENDING]])
|
319
326
|
segment = find_last_transaction_segment
|
320
327
|
end
|
321
328
|
|
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.7.1.
|
4
|
+
version: 3.7.1.182
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -40,7 +40,7 @@ cert_chain:
|
|
40
40
|
cHUySWFQWE92bTNUOEc0TzZxWnZobkxoL1VpZW4rK0RqOGVGQmVjVFBvTThw
|
41
41
|
VmpLM3BoNQpuL0V3dVpDY0U2Z2h0Q0NNCi0tLS0tRU5EIENFUlRJRklDQVRF
|
42
42
|
LS0tLS0K
|
43
|
-
date: 2013-12-
|
43
|
+
date: 2013-12-31 00:00:00.000000000 Z
|
44
44
|
dependencies:
|
45
45
|
- !ruby/object:Gem::Dependency
|
46
46
|
name: rake
|
@@ -985,7 +985,10 @@ post_install_message: ! "# New Relic Ruby Agent Release Notes #\n\n## v3.7.1 ##\
|
|
985
985
|
opt-in, but future releases may default it on.\n\n* Fix for missing HTTP time\n\n
|
986
986
|
\ The agent previously did not include connection establishment time for\n outgoing
|
987
987
|
Net::HTTP requests. This has been corrected, and reported HTTP\n timings should
|
988
|
-
now be more accurate.\n\
|
988
|
+
now be more accurate.\n\n* Fix for Mongo ensure_index instrumentation (3.7.1.182)\n\n
|
989
|
+
\ The Mongo instrumentation for ensure_index in 3.7.1.180 was not properly\n calling
|
990
|
+
through to the uninstrumented version of this method. This has been\n fixed in
|
991
|
+
3.7.1.182. Thanks to Yuki Miyauchi for the fix!\n\nSee https://github.com/newrelic/rpm/blob/master/CHANGELOG
|
989
992
|
for a full list of\nchanges.\n"
|
990
993
|
rdoc_options:
|
991
994
|
- --line-numbers
|
metadata.gz.sig
CHANGED
Binary file
|