epilog 0.9.2 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/lib/epilog/rails/active_record_subscriber.rb +12 -1
- data/lib/epilog/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 39632eca6b7556f3a11b14bc5944af2b15a8e5e9a9e693863d8214883e2653cf
|
|
4
|
+
data.tar.gz: e30a64e5b7f7547ab906ac91558c20535bc0e8157185cbadb4681aaa1159d8a2
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 07c7e5a705447e4969cc1839c6c17355a551bd410da15fac3d0566cf5d55a3a41ab8b872f5b0c7016c79652605c89701d31ffd7aeaf35f41a3b62d14febddde2
|
|
7
|
+
data.tar.gz: 41d6b4ed67de9f84b465c382f25e3d47e66f0d2c93c4c72f2e3204ff7cb351b754f0ccbfe39108df633f27e6466355c59f1ebee7377d60403da63a448b3b5f46
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.10.0
|
|
4
|
+
|
|
5
|
+
- Add support for Rails 8.0 and Rails 8.1
|
|
6
|
+
- Fix ActiveRecord subscriber for Rails 8.1 RuntimeRegistry API change
|
|
7
|
+
- Fix CI version pinning to use three-segment version constraints
|
|
8
|
+
|
|
3
9
|
## 0.9.2
|
|
4
10
|
|
|
5
11
|
- Fix double log issue in Rails 7.1+
|
|
@@ -6,7 +6,7 @@ module Epilog
|
|
|
6
6
|
IGNORE_PAYLOAD_NAMES = %w[SCHEMA EXPLAIN].freeze
|
|
7
7
|
|
|
8
8
|
def sql(event)
|
|
9
|
-
|
|
9
|
+
record_sql_runtime(event.duration)
|
|
10
10
|
|
|
11
11
|
return unless logger.debug?
|
|
12
12
|
|
|
@@ -23,6 +23,17 @@ module Epilog
|
|
|
23
23
|
|
|
24
24
|
private
|
|
25
25
|
|
|
26
|
+
# Rails 8.1 moved sql_runtime from a module-level accessor to
|
|
27
|
+
# ActiveRecord::RuntimeRegistry.stats.sql_runtime (a Stats object).
|
|
28
|
+
# See https://github.com/rails/rails/commit/7d12071e9fe94bd5c01a488ef61718fe88de65b4
|
|
29
|
+
def record_sql_runtime(duration)
|
|
30
|
+
if ActiveRecord::RuntimeRegistry.respond_to?(:sql_runtime=)
|
|
31
|
+
ActiveRecord::RuntimeRegistry.sql_runtime = (ActiveRecord::RuntimeRegistry.sql_runtime || 0) + duration
|
|
32
|
+
else
|
|
33
|
+
ActiveRecord::RuntimeRegistry.stats.sql_runtime += duration
|
|
34
|
+
end
|
|
35
|
+
end
|
|
36
|
+
|
|
26
37
|
def metrics(event)
|
|
27
38
|
{
|
|
28
39
|
query_runtime: event.duration.round(2)
|
data/lib/epilog/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: epilog
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.10.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Justin Howard
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-
|
|
11
|
+
date: 2026-03-20 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: combustion
|
|
@@ -120,7 +120,7 @@ licenses:
|
|
|
120
120
|
- MIT
|
|
121
121
|
metadata:
|
|
122
122
|
changelog_uri: https://github.com/nullscreen/epilog/blob/main/CHANGELOG.md
|
|
123
|
-
documentation_uri: https://www.rubydoc.info/gems/epilog/0.
|
|
123
|
+
documentation_uri: https://www.rubydoc.info/gems/epilog/0.10.0
|
|
124
124
|
rubygems_mfa_required: 'true'
|
|
125
125
|
post_install_message:
|
|
126
126
|
rdoc_options: []
|