skylight 3.1.4 → 5.3.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (126) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +465 -294
  3. data/CLA.md +1 -1
  4. data/CONTRIBUTING.md +11 -3
  5. data/ERRORS.md +3 -0
  6. data/LICENSE.md +8 -18
  7. data/README.md +1 -2
  8. data/bin/skylight +1 -1
  9. data/ext/extconf.rb +118 -122
  10. data/ext/libskylight.yml +8 -6
  11. data/ext/skylight_native.c +56 -100
  12. data/lib/skylight/api.rb +41 -27
  13. data/lib/skylight/cli/doctor.rb +68 -70
  14. data/lib/skylight/cli/helpers.rb +3 -5
  15. data/lib/skylight/cli/merger.rb +99 -92
  16. data/lib/skylight/cli.rb +40 -43
  17. data/lib/skylight/config.rb +656 -201
  18. data/lib/skylight/data/cacert.pem +730 -1023
  19. data/lib/skylight/deprecation.rb +17 -0
  20. data/lib/skylight/errors.rb +34 -16
  21. data/lib/skylight/extensions/source_location.rb +291 -0
  22. data/lib/skylight/extensions.rb +95 -0
  23. data/lib/skylight/formatters/http.rb +18 -0
  24. data/lib/skylight/gc.rb +99 -0
  25. data/lib/skylight/helpers.rb +82 -39
  26. data/lib/skylight/instrumenter.rb +339 -9
  27. data/lib/skylight/middleware.rb +147 -1
  28. data/lib/skylight/native.rb +71 -23
  29. data/lib/skylight/native_ext_fetcher.rb +39 -47
  30. data/lib/skylight/normalizers/action_controller/process_action.rb +68 -0
  31. data/lib/skylight/normalizers/action_controller/send_file.rb +51 -0
  32. data/lib/skylight/normalizers/action_dispatch/process_middleware.rb +22 -0
  33. data/lib/skylight/normalizers/action_dispatch/route_set.rb +27 -0
  34. data/lib/skylight/normalizers/action_view/render_collection.rb +24 -0
  35. data/lib/skylight/normalizers/action_view/render_layout.rb +25 -0
  36. data/lib/skylight/normalizers/action_view/render_partial.rb +23 -0
  37. data/lib/skylight/normalizers/action_view/render_template.rb +23 -0
  38. data/lib/skylight/normalizers/active_job/perform.rb +87 -0
  39. data/lib/skylight/normalizers/active_model_serializers/render.rb +32 -0
  40. data/lib/skylight/normalizers/active_record/instantiation.rb +16 -0
  41. data/lib/skylight/normalizers/active_record/sql.rb +20 -0
  42. data/lib/skylight/normalizers/active_storage.rb +28 -0
  43. data/lib/skylight/normalizers/active_support/cache.rb +11 -0
  44. data/lib/skylight/normalizers/active_support/cache_clear.rb +16 -0
  45. data/lib/skylight/normalizers/active_support/cache_decrement.rb +16 -0
  46. data/lib/skylight/normalizers/active_support/cache_delete.rb +16 -0
  47. data/lib/skylight/normalizers/active_support/cache_exist.rb +16 -0
  48. data/lib/skylight/normalizers/active_support/cache_fetch_hit.rb +16 -0
  49. data/lib/skylight/normalizers/active_support/cache_generate.rb +16 -0
  50. data/lib/skylight/normalizers/active_support/cache_increment.rb +16 -0
  51. data/lib/skylight/normalizers/active_support/cache_read.rb +16 -0
  52. data/lib/skylight/normalizers/active_support/cache_read_multi.rb +16 -0
  53. data/lib/skylight/normalizers/active_support/cache_write.rb +16 -0
  54. data/lib/skylight/normalizers/coach/handler_finish.rb +44 -0
  55. data/lib/skylight/normalizers/coach/middleware_finish.rb +33 -0
  56. data/lib/skylight/normalizers/couch_potato/query.rb +20 -0
  57. data/lib/skylight/normalizers/data_mapper/sql.rb +12 -0
  58. data/lib/skylight/normalizers/default.rb +24 -0
  59. data/lib/skylight/normalizers/elasticsearch/request.rb +20 -0
  60. data/lib/skylight/normalizers/faraday/request.rb +38 -0
  61. data/lib/skylight/normalizers/grape/endpoint.rb +28 -0
  62. data/lib/skylight/normalizers/grape/endpoint_render.rb +25 -0
  63. data/lib/skylight/normalizers/grape/endpoint_run.rb +39 -0
  64. data/lib/skylight/normalizers/grape/endpoint_run_filters.rb +20 -0
  65. data/lib/skylight/normalizers/grape/format_response.rb +20 -0
  66. data/lib/skylight/normalizers/graphiti/render.rb +22 -0
  67. data/lib/skylight/normalizers/graphiti/resolve.rb +31 -0
  68. data/lib/skylight/normalizers/graphql/base.rb +127 -0
  69. data/lib/skylight/normalizers/render.rb +79 -0
  70. data/lib/skylight/normalizers/sequel/sql.rb +12 -0
  71. data/lib/skylight/normalizers/shrine.rb +32 -0
  72. data/lib/skylight/normalizers/sql.rb +41 -0
  73. data/lib/skylight/normalizers.rb +157 -0
  74. data/lib/skylight/probes/action_controller.rb +52 -0
  75. data/lib/skylight/probes/action_dispatch/request_id.rb +33 -0
  76. data/lib/skylight/probes/action_dispatch/routing/route_set.rb +30 -0
  77. data/lib/skylight/probes/action_dispatch.rb +2 -0
  78. data/lib/skylight/probes/action_view.rb +42 -0
  79. data/lib/skylight/probes/active_job.rb +27 -0
  80. data/lib/skylight/probes/active_job_enqueue.rb +35 -0
  81. data/lib/skylight/probes/active_model_serializers.rb +50 -0
  82. data/lib/skylight/probes/active_record_async.rb +96 -0
  83. data/lib/skylight/probes/delayed_job.rb +144 -0
  84. data/lib/skylight/probes/elasticsearch.rb +45 -0
  85. data/lib/skylight/probes/excon/middleware.rb +65 -0
  86. data/lib/skylight/probes/excon.rb +25 -0
  87. data/lib/skylight/probes/faraday.rb +23 -0
  88. data/lib/skylight/probes/graphql.rb +38 -0
  89. data/lib/skylight/probes/httpclient.rb +44 -0
  90. data/lib/skylight/probes/middleware.rb +135 -0
  91. data/lib/skylight/probes/mongo.rb +169 -0
  92. data/lib/skylight/probes/mongoid.rb +6 -0
  93. data/lib/skylight/probes/net_http.rb +54 -0
  94. data/lib/skylight/probes/rack_builder.rb +37 -0
  95. data/lib/skylight/probes/redis.rb +68 -0
  96. data/lib/skylight/probes/sequel.rb +29 -0
  97. data/lib/skylight/probes/sinatra.rb +66 -0
  98. data/lib/skylight/probes/sinatra_add_middleware.rb +10 -10
  99. data/lib/skylight/probes/tilt.rb +25 -0
  100. data/lib/skylight/probes.rb +172 -0
  101. data/lib/skylight/railtie.rb +172 -15
  102. data/lib/skylight/sidekiq.rb +47 -0
  103. data/lib/skylight/sinatra.rb +2 -2
  104. data/lib/skylight/subscriber.rb +130 -0
  105. data/lib/skylight/test.rb +147 -0
  106. data/lib/skylight/trace.rb +331 -15
  107. data/lib/skylight/user_config.rb +60 -0
  108. data/lib/skylight/util/allocation_free.rb +26 -0
  109. data/lib/skylight/util/clock.rb +57 -0
  110. data/lib/skylight/util/component.rb +47 -9
  111. data/lib/skylight/util/deploy.rb +24 -40
  112. data/lib/skylight/util/gzip.rb +20 -0
  113. data/lib/skylight/util/hostname.rb +4 -4
  114. data/lib/skylight/util/http.rb +62 -71
  115. data/lib/skylight/util/instrumenter_method.rb +26 -0
  116. data/lib/skylight/util/logging.rb +136 -0
  117. data/lib/skylight/util/lru_cache.rb +36 -0
  118. data/lib/skylight/util/platform.rb +74 -0
  119. data/lib/skylight/util/proxy.rb +13 -0
  120. data/lib/skylight/util/ssl.rb +4 -28
  121. data/lib/skylight/util.rb +12 -0
  122. data/lib/skylight/vendor/cli/thor/rake_compat.rb +1 -1
  123. data/lib/skylight/version.rb +5 -1
  124. data/lib/skylight/vm/gc.rb +60 -0
  125. data/lib/skylight.rb +213 -24
  126. metadata +171 -53
metadata CHANGED
@@ -1,141 +1,169 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: skylight
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.4
4
+ version: 5.3.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tilde, Inc.
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-01-24 00:00:00.000000000 Z
11
+ date: 2022-10-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: skylight-core
14
+ name: activesupport
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 3.1.4
19
+ version: 5.2.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '='
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: 3.1.4
26
+ version: 5.2.0
27
27
  - !ruby/object:Gem::Dependency
28
- name: bundler
28
+ name: beefcake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '1.15'
33
+ version: '1.0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '1.15'
40
+ version: '1.0'
41
41
  - !ruby/object:Gem::Dependency
42
- name: rake
42
+ name: bundler
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - "~>"
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
- version: '10.0'
47
+ version: 1.17.3
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - "~>"
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
- version: '10.0'
54
+ version: 1.17.3
55
55
  - !ruby/object:Gem::Dependency
56
- name: rspec
56
+ name: puma
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: rack-test
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: rake
57
85
  requirement: !ruby/object:Gem::Requirement
58
86
  requirements:
59
87
  - - "~>"
60
88
  - !ruby/object:Gem::Version
61
- version: '3.7'
89
+ version: 13.0.1
62
90
  type: :development
63
91
  prerelease: false
64
92
  version_requirements: !ruby/object:Gem::Requirement
65
93
  requirements:
66
94
  - - "~>"
67
95
  - !ruby/object:Gem::Version
68
- version: '3.7'
96
+ version: 13.0.1
69
97
  - !ruby/object:Gem::Dependency
70
- name: rspec-collection_matchers
98
+ name: rake-compiler
71
99
  requirement: !ruby/object:Gem::Requirement
72
100
  requirements:
73
101
  - - "~>"
74
102
  - !ruby/object:Gem::Version
75
- version: '1.1'
103
+ version: 1.2.0
76
104
  type: :development
77
105
  prerelease: false
78
106
  version_requirements: !ruby/object:Gem::Requirement
79
107
  requirements:
80
108
  - - "~>"
81
109
  - !ruby/object:Gem::Version
82
- version: '1.1'
110
+ version: 1.2.0
83
111
  - !ruby/object:Gem::Dependency
84
- name: beefcake
112
+ name: rspec
85
113
  requirement: !ruby/object:Gem::Requirement
86
114
  requirements:
87
- - - "<"
115
+ - - "~>"
88
116
  - !ruby/object:Gem::Version
89
- version: '1.0'
117
+ version: '3.7'
90
118
  type: :development
91
119
  prerelease: false
92
120
  version_requirements: !ruby/object:Gem::Requirement
93
121
  requirements:
94
- - - "<"
122
+ - - "~>"
95
123
  - !ruby/object:Gem::Version
96
- version: '1.0'
124
+ version: '3.7'
97
125
  - !ruby/object:Gem::Dependency
98
- name: webmock
126
+ name: rspec-collection_matchers
99
127
  requirement: !ruby/object:Gem::Requirement
100
128
  requirements:
101
- - - ">="
129
+ - - "~>"
102
130
  - !ruby/object:Gem::Version
103
- version: '0'
131
+ version: '1.1'
104
132
  type: :development
105
133
  prerelease: false
106
134
  version_requirements: !ruby/object:Gem::Requirement
107
135
  requirements:
108
- - - ">="
136
+ - - "~>"
109
137
  - !ruby/object:Gem::Version
110
- version: '0'
138
+ version: '1.1'
111
139
  - !ruby/object:Gem::Dependency
112
- name: puma
140
+ name: rubocop
113
141
  requirement: !ruby/object:Gem::Requirement
114
142
  requirements:
115
- - - ">="
143
+ - - "~>"
116
144
  - !ruby/object:Gem::Version
117
- version: '0'
145
+ version: 1.31.0
118
146
  type: :development
119
147
  prerelease: false
120
148
  version_requirements: !ruby/object:Gem::Requirement
121
149
  requirements:
122
- - - ">="
150
+ - - "~>"
123
151
  - !ruby/object:Gem::Version
124
- version: '0'
152
+ version: 1.31.0
125
153
  - !ruby/object:Gem::Dependency
126
- name: rack-test
154
+ name: simplecov
127
155
  requirement: !ruby/object:Gem::Requirement
128
156
  requirements:
129
- - - ">="
157
+ - - "~>"
130
158
  - !ruby/object:Gem::Version
131
- version: '0'
159
+ version: 0.21.2
132
160
  type: :development
133
161
  prerelease: false
134
162
  version_requirements: !ruby/object:Gem::Requirement
135
163
  requirements:
136
- - - ">="
164
+ - - "~>"
137
165
  - !ruby/object:Gem::Version
138
- version: '0'
166
+ version: 0.21.2
139
167
  - !ruby/object:Gem::Dependency
140
168
  name: timecop
141
169
  requirement: !ruby/object:Gem::Requirement
@@ -151,20 +179,20 @@ dependencies:
151
179
  - !ruby/object:Gem::Version
152
180
  version: '0.9'
153
181
  - !ruby/object:Gem::Dependency
154
- name: rake-compiler
182
+ name: webmock
155
183
  requirement: !ruby/object:Gem::Requirement
156
184
  requirements:
157
- - - "~>"
185
+ - - ">="
158
186
  - !ruby/object:Gem::Version
159
- version: 1.0.4
187
+ version: '0'
160
188
  type: :development
161
189
  prerelease: false
162
190
  version_requirements: !ruby/object:Gem::Requirement
163
191
  requirements:
164
- - - "~>"
192
+ - - ">="
165
193
  - !ruby/object:Gem::Version
166
- version: 1.0.4
167
- description:
194
+ version: '0'
195
+ description:
168
196
  email:
169
197
  - engineering@tilde.io
170
198
  executables:
@@ -193,20 +221,108 @@ files:
193
221
  - lib/skylight/cli/merger.rb
194
222
  - lib/skylight/config.rb
195
223
  - lib/skylight/data/cacert.pem
224
+ - lib/skylight/deprecation.rb
196
225
  - lib/skylight/errors.rb
226
+ - lib/skylight/extensions.rb
227
+ - lib/skylight/extensions/source_location.rb
228
+ - lib/skylight/formatters/http.rb
229
+ - lib/skylight/gc.rb
197
230
  - lib/skylight/helpers.rb
198
231
  - lib/skylight/instrumenter.rb
199
232
  - lib/skylight/middleware.rb
200
233
  - lib/skylight/native.rb
201
234
  - lib/skylight/native_ext_fetcher.rb
235
+ - lib/skylight/normalizers.rb
236
+ - lib/skylight/normalizers/action_controller/process_action.rb
237
+ - lib/skylight/normalizers/action_controller/send_file.rb
238
+ - lib/skylight/normalizers/action_dispatch/process_middleware.rb
239
+ - lib/skylight/normalizers/action_dispatch/route_set.rb
240
+ - lib/skylight/normalizers/action_view/render_collection.rb
241
+ - lib/skylight/normalizers/action_view/render_layout.rb
242
+ - lib/skylight/normalizers/action_view/render_partial.rb
243
+ - lib/skylight/normalizers/action_view/render_template.rb
244
+ - lib/skylight/normalizers/active_job/perform.rb
245
+ - lib/skylight/normalizers/active_model_serializers/render.rb
246
+ - lib/skylight/normalizers/active_record/instantiation.rb
247
+ - lib/skylight/normalizers/active_record/sql.rb
248
+ - lib/skylight/normalizers/active_storage.rb
249
+ - lib/skylight/normalizers/active_support/cache.rb
250
+ - lib/skylight/normalizers/active_support/cache_clear.rb
251
+ - lib/skylight/normalizers/active_support/cache_decrement.rb
252
+ - lib/skylight/normalizers/active_support/cache_delete.rb
253
+ - lib/skylight/normalizers/active_support/cache_exist.rb
254
+ - lib/skylight/normalizers/active_support/cache_fetch_hit.rb
255
+ - lib/skylight/normalizers/active_support/cache_generate.rb
256
+ - lib/skylight/normalizers/active_support/cache_increment.rb
257
+ - lib/skylight/normalizers/active_support/cache_read.rb
258
+ - lib/skylight/normalizers/active_support/cache_read_multi.rb
259
+ - lib/skylight/normalizers/active_support/cache_write.rb
260
+ - lib/skylight/normalizers/coach/handler_finish.rb
261
+ - lib/skylight/normalizers/coach/middleware_finish.rb
262
+ - lib/skylight/normalizers/couch_potato/query.rb
263
+ - lib/skylight/normalizers/data_mapper/sql.rb
264
+ - lib/skylight/normalizers/default.rb
265
+ - lib/skylight/normalizers/elasticsearch/request.rb
266
+ - lib/skylight/normalizers/faraday/request.rb
267
+ - lib/skylight/normalizers/grape/endpoint.rb
268
+ - lib/skylight/normalizers/grape/endpoint_render.rb
269
+ - lib/skylight/normalizers/grape/endpoint_run.rb
270
+ - lib/skylight/normalizers/grape/endpoint_run_filters.rb
271
+ - lib/skylight/normalizers/grape/format_response.rb
272
+ - lib/skylight/normalizers/graphiti/render.rb
273
+ - lib/skylight/normalizers/graphiti/resolve.rb
274
+ - lib/skylight/normalizers/graphql/base.rb
275
+ - lib/skylight/normalizers/render.rb
276
+ - lib/skylight/normalizers/sequel/sql.rb
277
+ - lib/skylight/normalizers/shrine.rb
278
+ - lib/skylight/normalizers/sql.rb
279
+ - lib/skylight/probes.rb
280
+ - lib/skylight/probes/action_controller.rb
281
+ - lib/skylight/probes/action_dispatch.rb
282
+ - lib/skylight/probes/action_dispatch/request_id.rb
283
+ - lib/skylight/probes/action_dispatch/routing/route_set.rb
284
+ - lib/skylight/probes/action_view.rb
285
+ - lib/skylight/probes/active_job.rb
286
+ - lib/skylight/probes/active_job_enqueue.rb
287
+ - lib/skylight/probes/active_model_serializers.rb
288
+ - lib/skylight/probes/active_record_async.rb
289
+ - lib/skylight/probes/delayed_job.rb
290
+ - lib/skylight/probes/elasticsearch.rb
291
+ - lib/skylight/probes/excon.rb
292
+ - lib/skylight/probes/excon/middleware.rb
293
+ - lib/skylight/probes/faraday.rb
294
+ - lib/skylight/probes/graphql.rb
295
+ - lib/skylight/probes/httpclient.rb
296
+ - lib/skylight/probes/middleware.rb
297
+ - lib/skylight/probes/mongo.rb
298
+ - lib/skylight/probes/mongoid.rb
299
+ - lib/skylight/probes/net_http.rb
300
+ - lib/skylight/probes/rack_builder.rb
301
+ - lib/skylight/probes/redis.rb
302
+ - lib/skylight/probes/sequel.rb
303
+ - lib/skylight/probes/sinatra.rb
202
304
  - lib/skylight/probes/sinatra_add_middleware.rb
305
+ - lib/skylight/probes/tilt.rb
203
306
  - lib/skylight/railtie.rb
307
+ - lib/skylight/sidekiq.rb
204
308
  - lib/skylight/sinatra.rb
309
+ - lib/skylight/subscriber.rb
310
+ - lib/skylight/test.rb
205
311
  - lib/skylight/trace.rb
312
+ - lib/skylight/user_config.rb
313
+ - lib/skylight/util.rb
314
+ - lib/skylight/util/allocation_free.rb
315
+ - lib/skylight/util/clock.rb
206
316
  - lib/skylight/util/component.rb
207
317
  - lib/skylight/util/deploy.rb
318
+ - lib/skylight/util/gzip.rb
208
319
  - lib/skylight/util/hostname.rb
209
320
  - lib/skylight/util/http.rb
321
+ - lib/skylight/util/instrumenter_method.rb
322
+ - lib/skylight/util/logging.rb
323
+ - lib/skylight/util/lru_cache.rb
324
+ - lib/skylight/util/platform.rb
325
+ - lib/skylight/util/proxy.rb
210
326
  - lib/skylight/util/ssl.rb
211
327
  - lib/skylight/vendor/cli/highline.rb
212
328
  - lib/skylight/vendor/cli/highline/color_scheme.rb
@@ -248,11 +364,13 @@ files:
248
364
  - lib/skylight/vendor/cli/thor/util.rb
249
365
  - lib/skylight/vendor/cli/thor/version.rb
250
366
  - lib/skylight/version.rb
367
+ - lib/skylight/vm/gc.rb
251
368
  homepage: https://www.skylight.io
252
369
  licenses:
253
370
  - Nonstandard
254
- metadata: {}
255
- post_install_message:
371
+ metadata:
372
+ rubygems_mfa_required: 'true'
373
+ post_install_message:
256
374
  rdoc_options: []
257
375
  require_paths:
258
376
  - lib
@@ -260,15 +378,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
260
378
  requirements:
261
379
  - - ">="
262
380
  - !ruby/object:Gem::Version
263
- version: 2.2.7
381
+ version: '2.6'
264
382
  required_rubygems_version: !ruby/object:Gem::Requirement
265
383
  requirements:
266
384
  - - ">="
267
385
  - !ruby/object:Gem::Version
268
386
  version: '0'
269
387
  requirements: []
270
- rubygems_version: 3.0.2
271
- signing_key:
388
+ rubygems_version: 3.3.3
389
+ signing_key:
272
390
  specification_version: 4
273
391
  summary: Skylight is a smart profiler for Rails, Sinatra, and other Ruby apps.
274
392
  test_files: []