traceview 3.8.0-java → 3.8.1-java
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +12 -0
- data/README.md +3 -3
- data/lib/joboe_metal.rb +4 -4
- data/lib/oboe_metal.rb +3 -3
- data/lib/traceview/api/layerinit.rb +2 -2
- data/lib/traceview/api/logging.rb +12 -12
- data/lib/traceview/api/profiling.rb +6 -6
- data/lib/traceview/api/tracing.rb +1 -1
- data/lib/traceview/api/util.rb +1 -1
- data/lib/traceview/base.rb +14 -7
- data/lib/traceview/config.rb +8 -5
- data/lib/traceview/frameworks/padrino/templates.rb +4 -4
- data/lib/traceview/frameworks/rails.rb +2 -2
- data/lib/traceview/frameworks/rails/inst/action_controller.rb +6 -2
- data/lib/traceview/frameworks/rails/inst/action_controller2.rb +4 -2
- data/lib/traceview/frameworks/rails/inst/action_controller3.rb +5 -4
- data/lib/traceview/frameworks/rails/inst/action_controller4.rb +4 -2
- data/lib/traceview/frameworks/rails/inst/action_controller5.rb +22 -11
- data/lib/traceview/frameworks/rails/inst/action_controller5_api.rb +23 -12
- data/lib/traceview/frameworks/sinatra/templates.rb +4 -4
- data/lib/traceview/inst/bunny-client.rb +8 -8
- data/lib/traceview/inst/bunny-consumer.rb +1 -1
- data/lib/traceview/inst/curb.rb +19 -19
- data/lib/traceview/inst/dalli.rb +4 -4
- data/lib/traceview/inst/delayed_job.rb +4 -4
- data/lib/traceview/inst/em-http-request.rb +6 -6
- data/lib/traceview/inst/excon.rb +18 -18
- data/lib/traceview/inst/faraday.rb +13 -13
- data/lib/traceview/inst/http.rb +12 -12
- data/lib/traceview/inst/httpclient.rb +19 -19
- data/lib/traceview/inst/memcache.rb +5 -5
- data/lib/traceview/inst/memcached.rb +4 -4
- data/lib/traceview/inst/mongo.rb +6 -6
- data/lib/traceview/inst/moped.rb +28 -28
- data/lib/traceview/inst/rack.rb +24 -24
- data/lib/traceview/inst/redis.rb +6 -6
- data/lib/traceview/inst/resque.rb +6 -6
- data/lib/traceview/inst/rest-client.rb +4 -4
- data/lib/traceview/inst/sequel.rb +12 -12
- data/lib/traceview/inst/sidekiq-client.rb +3 -3
- data/lib/traceview/inst/sidekiq-worker.rb +3 -3
- data/lib/traceview/inst/twitter-cassandra.rb +17 -17
- data/lib/traceview/inst/typhoeus.rb +13 -13
- data/lib/traceview/method_profiling.rb +2 -2
- data/lib/traceview/ruby.rb +1 -1
- data/lib/traceview/util.rb +4 -4
- data/lib/traceview/version.rb +1 -1
- data/test/frameworks/rails3x_test.rb +105 -0
- data/test/frameworks/rails4x_test.rb +97 -0
- data/test/frameworks/rails5x_api_test.rb +98 -1
- data/test/frameworks/rails5x_test.rb +99 -2
- data/test/profiling/legacy_method_profiling_test.rb +1 -1
- data/test/support/backcompat_test.rb +2 -2
- data/test/support/config_test.rb +1 -1
- metadata +2 -2
data/lib/traceview/inst/excon.rb
CHANGED
@@ -11,27 +11,27 @@ module TraceView
|
|
11
11
|
|
12
12
|
def traceview_collect(params)
|
13
13
|
kvs = {}
|
14
|
-
kvs[
|
15
|
-
kvs[
|
16
|
-
kvs[
|
14
|
+
kvs[:IsService] = 1
|
15
|
+
kvs[:RemoteProtocol] = ::TraceView::Util.upcase(@data[:scheme])
|
16
|
+
kvs[:RemoteHost] = @data[:host]
|
17
17
|
|
18
18
|
# Conditionally log query args
|
19
19
|
if TraceView::Config[:excon][:log_args] && @data[:query]
|
20
20
|
if @data[:query].is_a?(Hash)
|
21
21
|
if RUBY_VERSION >= '1.9.2'
|
22
|
-
kvs[
|
22
|
+
kvs[:ServiceArg] = "#{@data[:path]}?#{URI.encode_www_form(@data[:query])}"
|
23
23
|
else
|
24
24
|
# An imperfect solution for the lack of URI.encode_www_form for Ruby versions before
|
25
25
|
# 1.9.2. We manually create a query string for reporting purposes only.
|
26
26
|
query_arg = ""
|
27
27
|
@data[:query].each_pair { |k,v| query_arg += "#{k}=#{v}?"; }
|
28
|
-
kvs[
|
28
|
+
kvs[:ServiceArg] = "#{@data[:path]}?#{query_arg.chop}"
|
29
29
|
end
|
30
30
|
else
|
31
|
-
kvs[
|
31
|
+
kvs[:ServiceArg] = "#{@data[:path]}?#{@data[:query]}"
|
32
32
|
end
|
33
33
|
else
|
34
|
-
kvs[
|
34
|
+
kvs[:ServiceArg] = @data[:path]
|
35
35
|
end
|
36
36
|
|
37
37
|
# In the case of HTTP pipelining, params could be an array of
|
@@ -41,12 +41,12 @@ module TraceView
|
|
41
41
|
params.each do |p|
|
42
42
|
methods << ::TraceView::Util.upcase(p[:method])
|
43
43
|
end
|
44
|
-
kvs[
|
45
|
-
kvs[
|
44
|
+
kvs[:HTTPMethods] = methods.join(', ')[0..1024]
|
45
|
+
kvs[:Pipeline] = true
|
46
46
|
else
|
47
|
-
kvs[
|
47
|
+
kvs[:HTTPMethod] = ::TraceView::Util.upcase(params[:method])
|
48
48
|
end
|
49
|
-
kvs[
|
49
|
+
kvs[:Backtrace] = TraceView::API.backtrace if TraceView::Config[:excon][:collect_backtraces]
|
50
50
|
kvs
|
51
51
|
rescue => e
|
52
52
|
TraceView.logger.debug "[traceview/debug] Error capturing excon KVs: #{e.message}"
|
@@ -57,7 +57,7 @@ module TraceView
|
|
57
57
|
|
58
58
|
def requests_with_traceview(pipeline_params)
|
59
59
|
responses = nil
|
60
|
-
TraceView::API.trace(
|
60
|
+
TraceView::API.trace(:excon, traceview_collect(pipeline_params)) do
|
61
61
|
responses = requests_without_traceview(pipeline_params)
|
62
62
|
end
|
63
63
|
responses
|
@@ -82,9 +82,9 @@ module TraceView
|
|
82
82
|
@data[:headers]['X-Trace'] = req_context unless blacklisted
|
83
83
|
|
84
84
|
kvs = traceview_collect(params)
|
85
|
-
kvs[
|
85
|
+
kvs[:Blacklisted] = true if blacklisted
|
86
86
|
|
87
|
-
TraceView::API.log_entry(
|
87
|
+
TraceView::API.log_entry(:excon, kvs)
|
88
88
|
kvs.clear
|
89
89
|
|
90
90
|
# The core excon call
|
@@ -95,11 +95,11 @@ module TraceView
|
|
95
95
|
# the datatype before trying to extract pertinent info
|
96
96
|
if response.is_a?(Excon::Response)
|
97
97
|
response_context = response.headers['X-Trace']
|
98
|
-
kvs[
|
98
|
+
kvs[:HTTPStatus] = response.status
|
99
99
|
|
100
100
|
# If we get a redirect, report the location header
|
101
101
|
if ((300..308).to_a.include? response.status.to_i) && response.headers.key?('Location')
|
102
|
-
kvs[
|
102
|
+
kvs[:Location] = response.headers['Location']
|
103
103
|
end
|
104
104
|
|
105
105
|
if response_context && !blacklisted
|
@@ -109,10 +109,10 @@ module TraceView
|
|
109
109
|
|
110
110
|
response
|
111
111
|
rescue => e
|
112
|
-
TraceView::API.log_exception(
|
112
|
+
TraceView::API.log_exception(:excon, e)
|
113
113
|
raise e
|
114
114
|
ensure
|
115
|
-
TraceView::API.log_exit(
|
115
|
+
TraceView::API.log_exit(:excon, kvs) unless params[:pipeline]
|
116
116
|
end
|
117
117
|
end
|
118
118
|
end
|
@@ -13,13 +13,13 @@ module TraceView
|
|
13
13
|
# Otherwise, the Net::HTTP instrumentation will send the service KVs
|
14
14
|
handle_service = !@builder.handlers.include?(Faraday::Adapter::NetHttp) &&
|
15
15
|
!@builder.handlers.include?(Faraday::Adapter::Excon)
|
16
|
-
TraceView::API.log_entry(
|
16
|
+
TraceView::API.log_entry(:faraday)
|
17
17
|
|
18
18
|
result = run_request_without_traceview(method, url, body, headers, &block)
|
19
19
|
|
20
20
|
kvs = {}
|
21
|
-
kvs[
|
22
|
-
kvs[
|
21
|
+
kvs[:Middleware] = @builder.handlers
|
22
|
+
kvs[:Backtrace] = TraceView::API.backtrace if TraceView::Config[:faraday][:collect_backtraces]
|
23
23
|
|
24
24
|
if handle_service
|
25
25
|
blacklisted = TraceView::API.blacklisted?(@url_prefix.to_s)
|
@@ -30,14 +30,14 @@ module TraceView
|
|
30
30
|
# Conditionally add the X-Trace header to the outgoing request
|
31
31
|
@headers['X-Trace'] = context unless blacklisted
|
32
32
|
|
33
|
-
kvs[
|
34
|
-
kvs[
|
35
|
-
kvs[
|
36
|
-
kvs[
|
37
|
-
kvs[
|
38
|
-
kvs[
|
33
|
+
kvs[:IsService] = 1
|
34
|
+
kvs[:RemoteProtocol] = (@url_prefix.scheme == 'https') ? 'HTTPS' : 'HTTP'
|
35
|
+
kvs[:RemoteHost] = @url_prefix.host
|
36
|
+
kvs[:RemotePort] = @url_prefix.port
|
37
|
+
kvs[:ServiceArg] = url
|
38
|
+
kvs[:HTTPMethod] = method
|
39
39
|
kvs[:HTTPStatus] = result.status
|
40
|
-
kvs[
|
40
|
+
kvs[:Blacklisted] = true if blacklisted
|
41
41
|
|
42
42
|
# Re-attach net::http edge unless it's blacklisted or if we don't have a
|
43
43
|
# valid X-Trace header
|
@@ -56,13 +56,13 @@ module TraceView
|
|
56
56
|
end
|
57
57
|
end
|
58
58
|
|
59
|
-
TraceView::API.log(
|
59
|
+
TraceView::API.log(:faraday, :info, kvs)
|
60
60
|
result
|
61
61
|
rescue => e
|
62
|
-
TraceView::API.log_exception(
|
62
|
+
TraceView::API.log_exception(:faraday, e)
|
63
63
|
raise e
|
64
64
|
ensure
|
65
|
-
TraceView::API.log_exit(
|
65
|
+
TraceView::API.log_exit(:faraday)
|
66
66
|
end
|
67
67
|
end
|
68
68
|
end
|
data/lib/traceview/inst/http.rb
CHANGED
@@ -17,7 +17,7 @@ if TraceView::Config[:nethttp][:enabled]
|
|
17
17
|
# Avoid cross host tracing for blacklisted domains
|
18
18
|
blacklisted = TraceView::API.blacklisted?(addr_port)
|
19
19
|
|
20
|
-
TraceView::API.trace('net-http') do
|
20
|
+
TraceView::API.trace(:'net-http') do
|
21
21
|
opts = {}
|
22
22
|
context = TraceView::Context.toString()
|
23
23
|
task_id = TraceView::XTrace.task_id(context)
|
@@ -26,20 +26,20 @@ if TraceView::Config[:nethttp][:enabled]
|
|
26
26
|
if args.length && args[0]
|
27
27
|
req = args[0]
|
28
28
|
|
29
|
-
opts[
|
30
|
-
opts[
|
31
|
-
opts[
|
29
|
+
opts[:IsService] = 1
|
30
|
+
opts[:RemoteProtocol] = use_ssl? ? :HTTPS : :HTTP
|
31
|
+
opts[:RemoteHost] = addr_port
|
32
32
|
|
33
33
|
# Conditionally log query params
|
34
34
|
if TraceView::Config[:nethttp][:log_args]
|
35
|
-
opts[
|
35
|
+
opts[:ServiceArg] = req.path
|
36
36
|
else
|
37
|
-
opts[
|
37
|
+
opts[:ServiceArg] = req.path.split('?').first
|
38
38
|
end
|
39
39
|
|
40
|
-
opts[
|
41
|
-
opts[
|
42
|
-
opts[
|
40
|
+
opts[:HTTPMethod] = req.method
|
41
|
+
opts[:Blacklisted] = true if blacklisted
|
42
|
+
opts[:Backtrace] = TraceView::API.backtrace if TraceView::Config[:nethttp][:collect_backtraces]
|
43
43
|
|
44
44
|
req['X-Trace'] = context unless blacklisted
|
45
45
|
end
|
@@ -64,17 +64,17 @@ if TraceView::Config[:nethttp][:enabled]
|
|
64
64
|
end
|
65
65
|
end
|
66
66
|
|
67
|
-
opts[
|
67
|
+
opts[:HTTPStatus] = resp.code
|
68
68
|
|
69
69
|
# If we get a redirect, report the location header
|
70
70
|
if ((300..308).to_a.include? resp.code.to_i) && resp.header["Location"]
|
71
|
-
opts[
|
71
|
+
opts[:Location] = resp.header["Location"]
|
72
72
|
end
|
73
73
|
|
74
74
|
next resp
|
75
75
|
ensure
|
76
76
|
# Log the info event with the KVs in opts
|
77
|
-
TraceView::API.log('net-http',
|
77
|
+
TraceView::API.log(:'net-http', :info, opts)
|
78
78
|
end
|
79
79
|
end
|
80
80
|
end
|
@@ -12,23 +12,23 @@ module TraceView
|
|
12
12
|
|
13
13
|
def traceview_collect(method, uri, query = nil)
|
14
14
|
kvs = {}
|
15
|
-
kvs[
|
15
|
+
kvs[:IsService] = 1
|
16
16
|
|
17
17
|
# Conditionally log URL query params
|
18
18
|
# Because of the hook points, the query arg can come in under <tt>query</tt>
|
19
19
|
# or as a part of <tt>uri</tt> (not both). Here we handle both cases.
|
20
20
|
if TraceView::Config[:httpclient][:log_args]
|
21
21
|
if query
|
22
|
-
kvs[
|
22
|
+
kvs[:RemoteURL] = uri.to_s + '?' + TraceView::Util.to_query(query)
|
23
23
|
else
|
24
|
-
kvs[
|
24
|
+
kvs[:RemoteURL] = uri.to_s
|
25
25
|
end
|
26
26
|
else
|
27
|
-
kvs[
|
27
|
+
kvs[:RemoteURL] = uri.to_s.split('?').first
|
28
28
|
end
|
29
29
|
|
30
|
-
kvs[
|
31
|
-
kvs[
|
30
|
+
kvs[:HTTPMethod] = ::TraceView::Util.upcase(method)
|
31
|
+
kvs[:Backtrace] = TraceView::API.backtrace if TraceView::Config[:httpclient][:collect_backtraces]
|
32
32
|
kvs
|
33
33
|
rescue => e
|
34
34
|
TraceView.logger.debug "[traceview/debug] Error capturing httpclient KVs: #{e.message}"
|
@@ -50,9 +50,9 @@ module TraceView
|
|
50
50
|
blacklisted = TraceView::API.blacklisted?(uri.hostname)
|
51
51
|
|
52
52
|
kvs = traceview_collect(method, uri, query)
|
53
|
-
kvs[
|
53
|
+
kvs[:Blacklisted] = true if blacklisted
|
54
54
|
|
55
|
-
TraceView::API.log_entry(
|
55
|
+
TraceView::API.log_entry(:httpclient, kvs)
|
56
56
|
kvs.clear
|
57
57
|
|
58
58
|
req_context = TraceView::Context.toString()
|
@@ -68,11 +68,11 @@ module TraceView
|
|
68
68
|
response = do_request_without_traceview(method, uri, query, body, header, &block)
|
69
69
|
|
70
70
|
response_context = response.headers['X-Trace']
|
71
|
-
kvs[
|
71
|
+
kvs[:HTTPStatus] = response.status_code
|
72
72
|
|
73
73
|
# If we get a redirect, report the location header
|
74
74
|
if ((300..308).to_a.include? response.status.to_i) && response.headers.key?("Location")
|
75
|
-
kvs[
|
75
|
+
kvs[:Location] = response.headers["Location"]
|
76
76
|
end
|
77
77
|
|
78
78
|
if response_context && !blacklisted
|
@@ -81,10 +81,10 @@ module TraceView
|
|
81
81
|
|
82
82
|
response
|
83
83
|
rescue => e
|
84
|
-
TraceView::API.log_exception(
|
84
|
+
TraceView::API.log_exception(:httpclient, e)
|
85
85
|
raise e
|
86
86
|
ensure
|
87
|
-
TraceView::API.log_exit(
|
87
|
+
TraceView::API.log_exit(:httpclient, kvs)
|
88
88
|
end
|
89
89
|
end
|
90
90
|
|
@@ -123,10 +123,10 @@ module TraceView
|
|
123
123
|
blacklisted = TraceView::API.blacklisted?(uri.hostname)
|
124
124
|
|
125
125
|
kvs = traceview_collect(method, uri)
|
126
|
-
kvs[
|
127
|
-
kvs[
|
126
|
+
kvs[:Blacklisted] = true if blacklisted
|
127
|
+
kvs[:Async] = 1
|
128
128
|
|
129
|
-
TraceView::API.log_entry(
|
129
|
+
TraceView::API.log_entry(:httpclient, kvs)
|
130
130
|
kvs.clear
|
131
131
|
|
132
132
|
req_context = TraceView::Context.toString()
|
@@ -143,11 +143,11 @@ module TraceView
|
|
143
143
|
end
|
144
144
|
|
145
145
|
response_context = response.headers['X-Trace']
|
146
|
-
kvs[
|
146
|
+
kvs[:HTTPStatus] = response.status_code
|
147
147
|
|
148
148
|
# If we get a redirect, report the location header
|
149
149
|
if ((300..308).to_a.include? response.status.to_i) && response.headers.key?("Location")
|
150
|
-
kvs[
|
150
|
+
kvs[:Location] = response.headers["Location"]
|
151
151
|
end
|
152
152
|
|
153
153
|
if response_context && !blacklisted
|
@@ -158,11 +158,11 @@ module TraceView
|
|
158
158
|
conn.push response if result.is_a?(::HTTPClient::Connection)
|
159
159
|
result
|
160
160
|
rescue => e
|
161
|
-
TraceView::API.log_exception(
|
161
|
+
TraceView::API.log_exception(:httpclient, e)
|
162
162
|
raise e
|
163
163
|
ensure
|
164
164
|
# TraceView::API.log_exit('httpclient', kvs.merge('Async' => 1))
|
165
|
-
TraceView::API.log_exit(
|
165
|
+
TraceView::API.log_exit(:httpclient, kvs)
|
166
166
|
end
|
167
167
|
end
|
168
168
|
end
|
@@ -17,7 +17,7 @@ module TraceView
|
|
17
17
|
report_kvs[:Backtrace] = TraceView::API.backtrace if TraceView::Config[:memcache][:collect_backtraces]
|
18
18
|
|
19
19
|
if TraceView.tracing?
|
20
|
-
TraceView::API.trace(
|
20
|
+
TraceView::API.trace(:memcache, report_kvs) do
|
21
21
|
send("#{m}_without_traceview", *args)
|
22
22
|
end
|
23
23
|
else
|
@@ -58,11 +58,11 @@ module TraceView
|
|
58
58
|
TraceView.logger.debug e.backtrace
|
59
59
|
end
|
60
60
|
|
61
|
-
TraceView::API.trace(
|
61
|
+
TraceView::API.trace(:memcache, { :KVOp => :get_multi }, :get_multi) do
|
62
62
|
values = get_multi_without_traceview(args)
|
63
63
|
|
64
64
|
info_kvs[:KVHitCount] = values.length
|
65
|
-
TraceView::API.log(
|
65
|
+
TraceView::API.log(:memcache, :info, info_kvs)
|
66
66
|
|
67
67
|
values
|
68
68
|
end
|
@@ -74,7 +74,7 @@ module TraceView
|
|
74
74
|
|
75
75
|
info_kvs = { :KVKey => cache_key, :RemoteHost => server.host }
|
76
76
|
info_kvs[:Backtrace] = TraceView::API.backtrace if TraceView::Config[:memcache][:collect_backtraces]
|
77
|
-
TraceView::API.log(
|
77
|
+
TraceView::API.log(:memcache, :info, info_kvs)
|
78
78
|
|
79
79
|
[server, cache_key]
|
80
80
|
else
|
@@ -87,7 +87,7 @@ module TraceView
|
|
87
87
|
|
88
88
|
info_kvs = { :KVHit => memcache_hit?(result) }
|
89
89
|
info_kvs[:Backtrace] = TraceView::API.backtrace if TraceView::Config[:memcache][:collect_backtraces]
|
90
|
-
TraceView::API.log(
|
90
|
+
TraceView::API.log(:memcache, :info, info_kvs)
|
91
91
|
|
92
92
|
result
|
93
93
|
end
|
@@ -20,14 +20,14 @@ module TraceView
|
|
20
20
|
opts[:RemoteHost] = rhost if rhost
|
21
21
|
end
|
22
22
|
|
23
|
-
TraceView::API.trace(
|
23
|
+
TraceView::API.trace(:memcache, opts) do
|
24
24
|
result = send("#{m}_without_traceview", *args)
|
25
25
|
|
26
26
|
info_kvs = {}
|
27
27
|
info_kvs[:KVHit] = memcache_hit?(result) if m == :get && args.length && args[0].class == String
|
28
28
|
info_kvs[:Backtrace] = TraceView::API.backtrace if TraceView::Config[:memcached][:collect_backtraces]
|
29
29
|
|
30
|
-
TraceView::API.log(
|
30
|
+
TraceView::API.log(:memcache, :info, info_kvs) unless info_kvs.empty?
|
31
31
|
result
|
32
32
|
end
|
33
33
|
end
|
@@ -57,7 +57,7 @@ module TraceView
|
|
57
57
|
layer_kvs = {}
|
58
58
|
layer_kvs[:KVOp] = :get_multi
|
59
59
|
|
60
|
-
TraceView::API.trace(
|
60
|
+
TraceView::API.trace(:memcache, layer_kvs || {}, :get_multi) do
|
61
61
|
begin
|
62
62
|
info_kvs = {}
|
63
63
|
info_kvs[:KVKeyCount] = keys.flatten.length
|
@@ -67,7 +67,7 @@ module TraceView
|
|
67
67
|
info_kvs[:KVHitCount] = values.length
|
68
68
|
info_kvs[:Backtrace] = TraceView::API.backtrace if TraceView::Config[:memcached][:collect_backtraces]
|
69
69
|
|
70
|
-
TraceView::API.log(
|
70
|
+
TraceView::API.log(:memcache, :info, info_kvs)
|
71
71
|
rescue
|
72
72
|
values = get_multi_without_traceview(keys, raw)
|
73
73
|
end
|
data/lib/traceview/inst/mongo.rb
CHANGED
@@ -60,7 +60,7 @@ if defined?(::Mongo) && (Gem.loaded_specs['mongo'].version.to_s < '2.0.0') && Tr
|
|
60
60
|
TraceView.logger.debug "[traceview/debug] #{__method__}:#{File.basename(__FILE__)}:#{__LINE__}: #{e.message}" if TraceView::Config[:verbose]
|
61
61
|
end
|
62
62
|
|
63
|
-
TraceView::API.trace(
|
63
|
+
TraceView::API.trace(:mongo, report_kvs) do
|
64
64
|
send("#{m}_without_traceview", *args)
|
65
65
|
end
|
66
66
|
end
|
@@ -94,7 +94,7 @@ if defined?(::Mongo) && (Gem.loaded_specs['mongo'].version.to_s < '2.0.0') && Tr
|
|
94
94
|
unless @selector.empty?
|
95
95
|
report_kvs[:Query] = @selector.to_json
|
96
96
|
else
|
97
|
-
report_kvs[:Query] =
|
97
|
+
report_kvs[:Query] = :all
|
98
98
|
end
|
99
99
|
report_kvs[:Limit] = @limit if @limit != 0
|
100
100
|
end
|
@@ -102,7 +102,7 @@ if defined?(::Mongo) && (Gem.loaded_specs['mongo'].version.to_s < '2.0.0') && Tr
|
|
102
102
|
TraceView.logger.debug "[traceview/debug] #{__method__}:#{File.basename(__FILE__)}:#{__LINE__}: #{e.message}" if TraceView::Config[:verbose]
|
103
103
|
end
|
104
104
|
|
105
|
-
TraceView::API.trace(
|
105
|
+
TraceView::API.trace(:mongo, report_kvs) do
|
106
106
|
send("#{m}_without_traceview", *args)
|
107
107
|
end
|
108
108
|
end
|
@@ -167,7 +167,7 @@ if defined?(::Mongo) && (Gem.loaded_specs['mongo'].version.to_s < '2.0.0') && Tr
|
|
167
167
|
TraceView.logger.debug "[traceview/debug] #{__method__}:#{File.basename(__FILE__)}:#{__LINE__}: #{e.message}" if TraceView::Config[:verbose]
|
168
168
|
end
|
169
169
|
|
170
|
-
TraceView::API.trace(
|
170
|
+
TraceView::API.trace(:mongo, report_kvs) do
|
171
171
|
send("#{m}_without_traceview", *args)
|
172
172
|
end
|
173
173
|
end
|
@@ -206,7 +206,7 @@ if defined?(::Mongo) && (Gem.loaded_specs['mongo'].version.to_s < '2.0.0') && Tr
|
|
206
206
|
TraceView.logger.debug "[traceview/debug] #{__method__}:#{File.basename(__FILE__)}:#{__LINE__}: #{e.message}" if TraceView::Config[:verbose]
|
207
207
|
end
|
208
208
|
|
209
|
-
TraceView::API.trace(
|
209
|
+
TraceView::API.trace(:mongo, report_kvs) do
|
210
210
|
send("#{m}_without_traceview", *args, &blk)
|
211
211
|
end
|
212
212
|
end
|
@@ -228,7 +228,7 @@ if defined?(::Mongo) && (Gem.loaded_specs['mongo'].version.to_s < '2.0.0') && Tr
|
|
228
228
|
TraceView.logger.debug "[traceview/debug] #{__method__}:#{File.basename(__FILE__)}:#{__LINE__}: #{e.message}" if TraceView::Config[:verbose]
|
229
229
|
end
|
230
230
|
|
231
|
-
TraceView::API.trace(
|
231
|
+
TraceView::API.trace(:mongo, report_kvs) do
|
232
232
|
send("#{m}_without_traceview", *args)
|
233
233
|
end
|
234
234
|
end
|