falcon 0.55.3 → 0.55.4

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: 15fd796344aad14ba00e77762e66e298565fca37152a58d0958e2de017eb3df2
4
- data.tar.gz: 3c93f36c92e58b888b3e22e04a934a53232c2c6e200d0dca0a9d0ea1b824ac04
3
+ metadata.gz: 518acbb2388840608c7abc42e802372d5b8cf547d0928a0164afc5bdd3aa7590
4
+ data.tar.gz: 9d37e38f1c95e19fa11a34c7ccebab765820401a48bea7e97b6a9ecf7e0c36d5
5
5
  SHA512:
6
- metadata.gz: 2b21c996cf29059c8f187b5b32d6502c55198e4f8311c270469db21ddbf3e56b47f84a27dbb504f53405be224a7eec6d1d3f38514c0c6601613f5994f0cda7e7
7
- data.tar.gz: cf27a313ae901795696b4a30d92b7e53b22e1497c6fa79b8044f1c363eabb47dc0b55d0ac39b5947d7056b1be7157e94affc26d182efe12bf1d1eaace9f95270
6
+ metadata.gz: 05ae47c057c66f6a89e84d2f46a2a4db66109716a1035af63bfd0e2db4272d51a1e6702bf7f915a32b1f9479c991ca7de622d7ed96ac1ddfa7c6e234a866299b
7
+ data.tar.gz: 4ceeb8958477cff0ffc308ea911e7844bebb6343cf464a20e35e749098a104cf2f807f92d56fb891eeb4f2135cbec638b1518b7b7362ee926658250f19d09898
checksums.yaml.gz.sig CHANGED
Binary file
@@ -11,8 +11,9 @@ module Falcon
11
11
  # Wraps a response body and decrements a metric after the body is closed.
12
12
  #
13
13
  # Runs close on the underlying body first (which invokes rack.response_finished),
14
- # then decrements the metric. Use this so requests_active stays elevated until
15
- # the request is fully finished (including response_finished callbacks).
14
+ # then decrements the metric, even if closing raises. Use this so requests_active
15
+ # stays elevated until the request is fully finished (including response_finished
16
+ # callbacks), without leaking if close reports an error.
16
17
  class RequestFinished < Protocol::HTTP::Body::Wrapper
17
18
  # Wrap a response body with a metric.
18
19
  #
@@ -56,7 +57,7 @@ module Falcon
56
57
  # @parameter error [Exception, nil] Optional error that caused the close.
57
58
  def close(error = nil)
58
59
  super
59
-
60
+ ensure
60
61
  @metric&.decrement
61
62
  @metric = nil
62
63
  end
@@ -5,5 +5,5 @@
5
5
 
6
6
  # @namespace
7
7
  module Falcon
8
- VERSION = "0.55.3"
8
+ VERSION = "0.55.4"
9
9
  end
data/readme.md CHANGED
@@ -47,6 +47,10 @@ Please see the [project documentation](https://socketry.github.io/falcon/) for m
47
47
 
48
48
  Please see the [project releases](https://socketry.github.io/falcon/releases/index) for all releases.
49
49
 
50
+ ### v0.55.4
51
+
52
+ - Ensure `requests_active` is decremented if closing the response body raises.
53
+
50
54
  ### v0.55.3
51
55
 
52
56
  - Decrement `requests_active` in `Falcon::Server#call` when `super` or `Falcon::Body::RequestFinished.wrap` raises, so utilization metrics are not leaked on error paths.
@@ -91,10 +95,6 @@ Please see the [project releases](https://socketry.github.io/falcon/releases/ind
91
95
  - Introduce <code class="language-ruby">Falcon::Environment::Server\#make\_server</code> which gives you full control over the server creation process.
92
96
  - [Introduce `Async::Container::Supervisor`.](https://socketry.github.io/falcon/releases/index#introduce-async::container::supervisor.)
93
97
 
94
- ### v0.50.0
95
-
96
- - Add <code class="language-ruby">Falcon::Environment::Server\#endpoint\_options</code> to allow configuration of the endpoint options more easily.
97
-
98
98
  ## Contributing
99
99
 
100
100
  We welcome contributions to this project.
data/releases.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Releases
2
2
 
3
+ ## v0.55.4
4
+
5
+ - Ensure `requests_active` is decremented if closing the response body raises.
6
+
3
7
  ## v0.55.3
4
8
 
5
9
  - Decrement `requests_active` in `Falcon::Server#call` when `super` or `Falcon::Body::RequestFinished.wrap` raises, so utilization metrics are not leaked on error paths.
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: falcon
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.55.3
4
+ version: 0.55.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
@@ -312,7 +312,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
312
312
  - !ruby/object:Gem::Version
313
313
  version: '0'
314
314
  requirements: []
315
- rubygems_version: 4.0.6
315
+ rubygems_version: 4.0.10
316
316
  specification_version: 4
317
317
  summary: A fast, asynchronous, rack-compatible web server.
318
318
  test_files: []
metadata.gz.sig CHANGED
Binary file