simple_apm 1.0.6 → 1.0.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/simple_apm/error_logger.rb +8 -0
- data/lib/simple_apm/version.rb +1 -1
- data/lib/simple_apm/worker.rb +5 -3
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e8c989664fa3b8d390ac868ac144adf3f8c75114374d4843cb80c6ec36080eed
|
4
|
+
data.tar.gz: fdc007de42402503a588d7775d2a410527c125c012ff5b5c56b9d3581c1379f9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d0327ea89887bdc55829cbb976726b991ef836e349eedea1ee98c517d1e2e24bb86cb82950ddbfdade6c9718fb3826bbe4c2fe4261fd6158a56fb44d5acd7a49
|
7
|
+
data.tar.gz: c45971ff9bf1fd1683ab5110988cf0f37e52431ae202891ab2d4345f7497ed312e01bc7074cee1b953e745deaf34cdac79383c9155e3e5713c7774545cd0b136
|
data/lib/simple_apm/version.rb
CHANGED
data/lib/simple_apm/worker.rb
CHANGED
@@ -31,6 +31,7 @@ module SimpleApm
|
|
31
31
|
if request_id.present?
|
32
32
|
if need_skip
|
33
33
|
SimpleApm::Sql.delete_by_request_id(request_id)
|
34
|
+
SimpleApm::HttpRequest.delete_by_request_id(request_id)
|
34
35
|
else
|
35
36
|
action_name = "#{payload[:controller]}##{payload[:action]}"
|
36
37
|
memory_during = completed_memory - started_memory rescue 0
|
@@ -62,11 +63,12 @@ module SimpleApm
|
|
62
63
|
SimpleApm::Request.create info
|
63
64
|
else
|
64
65
|
SimpleApm::Sql.delete_by_request_id(request_id)
|
66
|
+
SimpleApm::HttpRequest.delete_by_request_id(request_id)
|
65
67
|
end
|
66
68
|
end
|
67
69
|
end
|
68
70
|
rescue => e
|
69
|
-
|
71
|
+
ErrorLogger.log e.backtrace.join("\n")
|
70
72
|
end
|
71
73
|
end
|
72
74
|
|
@@ -93,7 +95,7 @@ module SimpleApm
|
|
93
95
|
SimpleApm::Sql.create request_id, info
|
94
96
|
end
|
95
97
|
rescue => e
|
96
|
-
|
98
|
+
ErrorLogger.log e.backtrace.join("\n")
|
97
99
|
end
|
98
100
|
end
|
99
101
|
|
@@ -119,7 +121,7 @@ module SimpleApm
|
|
119
121
|
SimpleApm::HttpRequest.create request_id, info
|
120
122
|
end
|
121
123
|
rescue => e
|
122
|
-
|
124
|
+
ErrorLogger.log e.backtrace.join("\n")
|
123
125
|
end
|
124
126
|
end
|
125
127
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: simple_apm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- yuanyin.xia
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-08-
|
11
|
+
date: 2018-08-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -103,6 +103,7 @@ files:
|
|
103
103
|
- lib/generators/simple_apm/install_generator.rb
|
104
104
|
- lib/simple_apm.rb
|
105
105
|
- lib/simple_apm/engine.rb
|
106
|
+
- lib/simple_apm/error_logger.rb
|
106
107
|
- lib/simple_apm/net_http.rb
|
107
108
|
- lib/simple_apm/redis.rb
|
108
109
|
- lib/simple_apm/setting.rb
|