rails-profiler 0.47.0 → 0.47.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4534b3dd777b1379a70f6bd6f0eb770dae0f3ad8e84e5a251063259ddcfd7d08
4
- data.tar.gz: bda18dfec9a07bf1341f0317edce91f7d0b076c42de43203a2a04ad354af17f6
3
+ metadata.gz: 91bc44ba5b4333966b0445527c4ed592fb2d9ded75e5560b1ffe8a9dd94bf3ea
4
+ data.tar.gz: 98b7b5b33220028a7402a25ce2594efcace4805a114433443a30b3a6adcc3e61
5
5
  SHA512:
6
- metadata.gz: 5db82256a78d4caac6d74fad99cb94a3773b25b4d2a2b8c4dafd4a279cd02437e0fae119a2fb8f33a5bc214e425682f7cdc27dd60daa347dfb08334579726be2
7
- data.tar.gz: ffcddd382edbccc0f7090fc2d9bd38d9dae60f20e0ecdb0fb78d5a03429bda11e96498833bf0312a8c61b1c303fd2c6b7265bd94724dfa4be5f940665e3a1017
6
+ metadata.gz: 8e3f5b37812f455601e1d8f6656df747ae01161a71f3556561b85869652511382e3bd506caeb7a05a3319c638ab2c4d2578e92b3ea7cdb8db5d3096bb3d223e8
7
+ data.tar.gz: 1551af3171c718e4fa17a7e10dbc9ee6f6fdee63361a2aa70ef490c49b62bf2f0083637ed7245631838e321ad4d6513235e9bc5bec43ab83fb154ccc47a0bc8c
data/CHANGELOG.md CHANGED
@@ -19,6 +19,14 @@ every commit of every tag interval is accounted for one way or the other.
19
19
 
20
20
  ## [Unreleased]
21
21
 
22
+ ## [0.47.1] - 2026-11-07
23
+
24
+ <!-- stamped -->
25
+
26
+ ### Fixed
27
+
28
+ - The live event stream (`GET /_profiler/api/stream`) reached the client only when it ended, 5 minutes later, on Rails 7: `Rack::ETag` read the whole body to digest it. The response now carries a `Last-Modified`, which tells it to leave the stream alone, so the events arrive as they happen on every Rails version.
29
+
22
30
  ## [0.47.0] - 2026-11-07
23
31
 
24
32
  <!-- stamped -->
@@ -27,8 +27,12 @@ module Profiler
27
27
 
28
28
  begin
29
29
  response.headers["Content-Type"] = "text/event-stream"
30
- response.headers["Cache-Control"] = "no-cache"
30
+ response.headers["Cache-Control"] = "no-cache, no-store"
31
31
  response.headers["X-Accel-Buffering"] = "no"
32
+ # Rack::ETag reads a body that answers to_ary whole to digest it, unless the response already
33
+ # carries an ETag or a Last-Modified: on Rails 7 that would hold the stream back until it
34
+ # ends. A stream has neither a digest nor a date worth anything, this only says so.
35
+ response.headers["Last-Modified"] = Time.now.httpdate
32
36
  self.response_body = Profiler::Live::EventStream.new(
33
37
  storage: Profiler.storage, tokens: tokens, lease: lease, cursors: cursors
34
38
  )
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Profiler
4
- VERSION = "0.47.0"
4
+ VERSION = "0.47.1"
5
5
 
6
6
  GEM_ROOT = File.expand_path("../..", __dir__)
7
7
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails-profiler
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.47.0
4
+ version: 0.47.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sébastien Duplessy