omq 0.6.1 → 0.6.2

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.
Files changed (5) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +21 -0
  3. data/README.md +15 -6
  4. data/lib/omq/version.rb +1 -1
  5. metadata +8 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 06ab82b849c36e97a62cfe21ddd1ecdce9901245b5d8ddb294128911e74abf03
4
- data.tar.gz: 6c7ca53bc5163e56da92036a63f1d16fcfe4de2298fdc91fc4389d93d0e21b4b
3
+ metadata.gz: d98f48b27c695817b0e57b18fb2bab2f1a7d5ed87bed3c70d66b5eda3c06c77b
4
+ data.tar.gz: 6a8473e8d082df4e154038175ac56c7b6aadbfeb2ecc52f672c377898b35e4d9
5
5
  SHA512:
6
- metadata.gz: '096b416cdc83f3f6773e770bdbcf4a5cc0100269867ff934623c3274826546ccc8129d862428bbcc8a042d13395b503afa329bdd6c75e99e7fb569c7b73e8a48'
7
- data.tar.gz: 62df2878bcef5f3a4d5b1c0ae2d1522853e81aaa4f03363c39fbd809e92b3c214eba1ba70c39850a7e86cace6a0c1d2290fd3d41809af22467f68a8e43d594ac
6
+ metadata.gz: 57fca38f85a1b65ce6275617aca7b88c420b59206dc41ae5d8b0d49824c45d4af723dd7d9481f191c768fdb691632df962c8d9e7b21452be32be5469910ffa78
7
+ data.tar.gz: d183e5bff6e12f332126479cf3040d9666c8bf33efebd30c107198f0a9b88fd8ccd5fa58727cd1efdacea221dad05539ff7cadc019a8714a44139566ea4b3249
data/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.6.2 — 2026-03-30
4
+
5
+ ### Improved
6
+
7
+ - **Gemspec summary** — highlights the CLI's composable pipeline
8
+ capabilities (pipe, filter, transform, formats, Ractor parallelism).
9
+ - **README CLI section** — added `pipe`, `--transient`, `-P/--parallel`,
10
+ `BEGIN{}/END{}` blocks, `$_` variable, and `--marshal` format.
11
+
12
+ ### Fixed
13
+
14
+ - **Flaky memory leak tests on CI** — replaced global `ObjectSpace`
15
+ counting with `WeakRef` tracking of specific objects, retrying GC
16
+ until collected. No longer depends on GC generational timing.
17
+
3
18
  ## 0.6.1 — 2026-03-30
4
19
 
5
20
  ### Improved
@@ -11,6 +26,12 @@
11
26
  `pipeline_ractors.sh` now derive absolute paths from the script
12
27
  location instead of assuming the working directory is the project root.
13
28
 
29
+ ### Fixed
30
+
31
+ - **Flaky memory leak tests on CI** — replaced global `ObjectSpace`
32
+ counting with `WeakRef` tracking of specific objects, retrying GC
33
+ until collected. No longer depends on GC generational timing.
34
+
14
35
  ## 0.6.0 — 2026-03-30
15
36
 
16
37
  ### Added
data/README.md CHANGED
@@ -167,10 +167,15 @@ echo "weather.nyc 72F" | omq pub -c tcp://localhost:5556 -d 0.3
167
167
  tail -f /var/log/syslog | omq push -c tcp://collector:5557
168
168
  omq pull -b tcp://:5557 -e '$F.first.include?("error") ? $F : nil'
169
169
 
170
- # Multipart messages via tabs
171
- printf "routing-key\tpayload data" | omq push -c tcp://localhost:5557
172
- omq pull -b tcp://:5557
173
- # => routing-key payload data
170
+ # Pipe: PULL eval → PUSH in one process
171
+ omq pipe -c ipc://@work -c ipc://@sink -e '$F.map(&:upcase)'
172
+
173
+ # Pipe with 4 Ractor workers for CPU parallelism
174
+ omq pipe -c ipc://@work -c ipc://@sink -P 4 \
175
+ -r ./fib.rb -e 'fib(Integer($_)).to_s'
176
+
177
+ # Exit when all peers disconnect (pipeline workers, sinks)
178
+ omq pipe -c ipc://@work -c ipc://@sink --transient -e '$F'
174
179
 
175
180
  # JSONL for structured data
176
181
  echo '["key","value"]' | omq push -c tcp://localhost:5557 -J
@@ -186,14 +191,18 @@ omq rep -b tcp://:5555 -D "secret" --curve-server
186
191
  omq req -c tcp://localhost:5555 --curve-server-key '...'
187
192
  ```
188
193
 
189
- The `-e` flag runs Ruby inside the socket instance — the full socket API (`self <<`, `send`, `subscribe`, ...) is available. Use `-r` to require gems:
194
+ The `-e` flag runs Ruby inside the socket instance — the full socket API (`self <<`, `send`, `subscribe`, ...) is available. `$F` is the message parts array, `$_` is the first part. Use `-r` to require gems:
190
195
 
191
196
  ```sh
192
197
  omq sub -c tcp://localhost:5556 -s "" -r json \
193
198
  -e 'JSON.parse($F.first)["temperature"]'
199
+
200
+ # BEGIN/END blocks (like awk) — accumulate and summarize
201
+ omq pull -b tcp://:5557 \
202
+ -e 'BEGIN{ @sum = 0 } @sum += Integer($_); next END{ puts @sum }'
194
203
  ```
195
204
 
196
- Formats: `--ascii` (default, tab-separated), `--quoted`, `--raw`, `--jsonl`, `--msgpack`. See `omq --help` for all options.
205
+ Formats: `--ascii` (default, tab-separated), `--quoted`, `--raw`, `--jsonl`, `--msgpack`, `--marshal`. See `omq --help` for all options.
197
206
 
198
207
  ## Interop with native ZMQ
199
208
 
data/lib/omq/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module OMQ
4
- VERSION = "0.6.1"
4
+ VERSION = "0.6.2"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omq
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.1
4
+ version: 0.6.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Patrik Wenger
@@ -37,8 +37,12 @@ dependencies:
37
37
  - - "~>"
38
38
  - !ruby/object:Gem::Version
39
39
  version: '0.11'
40
- description: Pure Ruby implementation of the ZMTP 3.1 wire protocol (ZeroMQ) using
41
- the Async gem. No native libraries required.
40
+ description: Pure Ruby implementation of the ZMTP 3.1 wire protocol (ZeroMQ) with
41
+ all socket types (REQ/REP, PUB/SUB, PUSH/PULL, DEALER/ROUTER, and draft types) and
42
+ TCP/IPC/inproc transports. Includes an `omq` CLI for composable message pipelines
43
+ — pipe, filter, and transform across processes with Ruby eval, multiple formats
44
+ (JSON, msgpack, marshal), Ractor parallelism, and compression. No native libraries
45
+ required.
42
46
  email:
43
47
  - paddor@gmail.com
44
48
  executables:
@@ -137,5 +141,5 @@ required_rubygems_version: !ruby/object:Gem::Requirement
137
141
  requirements: []
138
142
  rubygems_version: 4.0.6
139
143
  specification_version: 4
140
- summary: OMQ pure Ruby ZeroMQ (ZMTP 3.1)
144
+ summary: Pure Ruby ZMQ library + CLI
141
145
  test_files: []