wreq-rb 0.5.1-aarch64-linux → 0.6.0-aarch64-linux

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: 81136f1b3df3f8dd9186c9fe73cd5cfbdb633027724da6688447ab34cd98da63
4
- data.tar.gz: 805228038bb0f9b54b93beec65f069221cc9ddd393c80a878b3db614433fb6fb
3
+ metadata.gz: f457452d4537ace62b3dbcdca8a4e136567db1df1b41eec6bd3e9a578f76e8a5
4
+ data.tar.gz: 20e556e4a8f9565f666398668961314f1562ed291c1ce1b0a1e7184f00c0e0b3
5
5
  SHA512:
6
- metadata.gz: b1b57a77798fdb61ef986680b7c508ef073dc9ec6a9b5393e108e7ed5a5433bfa8f72159cc8e07c47b7719d0d054a9f829e5bc870ce205331a7624651152672d
7
- data.tar.gz: 9af68ee94edd868ab579dbd40aebd3654b5d3fe363f07325eea8426a209a055bf2a0a1d3c70f23848e07effce78435b2cd898771b95765f4fd2a7b2a4c7af7e0
6
+ metadata.gz: f4181f18f37f7c35caa01f4b1846601e440cacaefd746540826b43279f49f83905f2e4a21a8111759bcff097427111d6991e2555e7e8ccd2784dd45f04aff81e
7
+ data.tar.gz: cdec49207ea682f8b9cdb4c51825ed0d5d2bfaf7e87cece6433b3a4fa1e69f700e35efdc91f48db1a040419a6aa6f1f907380d736373906a21ceeff042672053
data/README.md CHANGED
@@ -114,6 +114,34 @@ All methods are available on both `Wreq` (module-level) and `Wreq::Client` (inst
114
114
  | `head(url, **opts)` | HEAD request |
115
115
  | `options(url, **opts)` | OPTIONS request |
116
116
 
117
+ ### Batch Requests
118
+
119
+ `Wreq::Client#request_batch` runs many requests concurrently inside a **single**
120
+ GVL release, multiplexed over the client's connection pool. This avoids one Ruby
121
+ thread per request.
122
+
123
+ ```ruby
124
+ client = Wreq::Client.new(redirect: false, pool_max_idle_per_host: 32)
125
+
126
+ responses = client.request_batch(urls, concurrency: 128)
127
+ ```
128
+
129
+ Each element of the array is either a URL string or a hash:
130
+
131
+ ```ruby
132
+ client.request_batch([
133
+ "https://example.com/a", # GET
134
+ { method: :put, url: "https://example.com/b", body: "hi" }
135
+ ], concurrency: 32)
136
+ ```
137
+
138
+ - Results are returned **in input order**.
139
+ - Each element is a `Wreq::Response` **or** a `Wreq::Error` — a single failed
140
+ request never discards the rest of the batch. Errors are returned, not raised.
141
+ - `concurrency` caps the number of in-flight requests and defaults to `16`.
142
+ - `cancel` and Ruby thread interrupts abort the whole batch, raising
143
+ `Wreq::Error` with `"request interrupted"`.
144
+
117
145
  ### Cancelling Requests
118
146
 
119
147
  Call `cancel` on a client to interrupt all in-flight requests immediately:
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Wreq
4
- VERSION = "0.5.1"
4
+ VERSION = "0.6.0"
5
5
  end
Binary file
Binary file
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: wreq-rb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.6.0
5
5
  platform: aarch64-linux
6
6
  authors:
7
7
  - Yicheng Zhou
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2026-06-09 00:00:00.000000000 Z
12
+ date: 2026-08-28 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: An ergonomic Ruby HTTP client powered by Rust's wreq library, featuring
15
15
  TLS fingerprint emulation (JA3/JA4), HTTP/2 support, cookie handling, proxy support,