prosody 0.1.2 → 0.2.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: 50b24e61e2dffddd6de734d1f7d46bbcd2cdc5351ff4205f09d1ed038a289a22
4
- data.tar.gz: c7d7b1533053dd7a30a7d370216f29202e4ff45eb137244de556eb1037398785
3
+ metadata.gz: 99de4b7f1bc9381684dbaa3443478449aae693c9c49920947bc959d2ab3737f5
4
+ data.tar.gz: aa25eaf9af86d4f37746769cb61e57adcc462eebd5ab8d382039a97e246e8f2f
5
5
  SHA512:
6
- metadata.gz: 0b9478cb2ea9568f9a498b109638fa504d42a5ba802cdc3dc824d4495871c6670f6325593a10ec3a74075ae2616a1a6df292f45f7694575267bfa21da051af30
7
- data.tar.gz: 3563ae9225b5ab4373240e739ae950eabe7fbc5353d0de76fec05b954335fcb18892af74581e238543e5071d0eef10ae5932d0aaed37f0dc71f7c7926740e82f
6
+ metadata.gz: 143d9206f81101ca16caa4bde5dfd565e224279fa81f5f5acc2a83a4896f8eb189da2a4a3019326c992f70367ad4d1241e75dc844330cb7ff8e05bc7b623cb82
7
+ data.tar.gz: eb3bbb3b74476fde953ec6413ace312c18d6d28cb181fa6f6b2a15756ab94d72940036afeb67b0bbe724aebbc41fc06b12af2ece11df672678843cd49c84cd01
@@ -1,3 +1,3 @@
1
1
  {
2
- ".": "0.1.2"
2
+ ".": "0.2.1"
3
3
  }
data/CHANGELOG.md CHANGED
@@ -1,5 +1,36 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.2.1](https://github.com/prosody-events/prosody-rb/compare/prosody/v0.2.0...prosody/v0.2.1) (2026-05-11)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **ci:** define ERROR_COMMITMENT_MINIMUM for Windows cross-compile ([#22](https://github.com/prosody-events/prosody-rb/issues/22)) ([870d821](https://github.com/prosody-events/prosody-rb/commit/870d82132868b376ae9f1e80181de80ff3859dc3))
9
+
10
+ ## [0.2.0](https://github.com/prosody-events/prosody-rb/compare/prosody/v0.1.3...prosody/v0.2.0) (2026-05-11)
11
+
12
+
13
+ ### Features
14
+
15
+ * **deps:** upgrade prosody to 0.3.0 ([#20](https://github.com/prosody-events/prosody-rb/issues/20)) ([4c7a7f0](https://github.com/prosody-events/prosody-rb/commit/4c7a7f020ce537696073f22f649b05b48b8b513a))
16
+
17
+
18
+ ### Bug Fixes
19
+
20
+ * **deps:** upgrade prosody to 0.2.1 ([#17](https://github.com/prosody-events/prosody-rb/issues/17)) ([24300d0](https://github.com/prosody-events/prosody-rb/commit/24300d08d0f5046b4d7fccf4f8fdf32cc05e2a71))
21
+
22
+
23
+ ### Performance Improvements
24
+
25
+ * **deps:** migrate from jemalloc to mimalloc v3 ([#19](https://github.com/prosody-events/prosody-rb/issues/19)) ([02aa0dd](https://github.com/prosody-events/prosody-rb/commit/02aa0dd6baeabc1a5531c98e4cd09e401f8debf4))
26
+
27
+ ## [0.1.3](https://github.com/prosody-events/prosody-rb/compare/prosody/v0.1.2...prosody/v0.1.3) (2026-04-21)
28
+
29
+
30
+ ### Bug Fixes
31
+
32
+ * **tracing:** set error status on on_message and on_timer spans ([#14](https://github.com/prosody-events/prosody-rb/issues/14)) ([849c021](https://github.com/prosody-events/prosody-rb/commit/849c0212b88d1069fc728ab38e9e05d79408c093))
33
+
3
34
  ## [0.1.2](https://github.com/prosody-events/prosody-rb/compare/prosody/v0.1.1...prosody/v0.1.2) (2026-04-20)
4
35
 
5
36
 
data/Cargo.lock CHANGED
@@ -296,9 +296,9 @@ checksum = "1e748733b7cbc798e1434b6ac524f0c1ff2ab456fe201501e6497c8417a4fc33"
296
296
 
297
297
  [[package]]
298
298
  name = "cc"
299
- version = "1.2.60"
299
+ version = "1.2.62"
300
300
  source = "registry+https://github.com/rust-lang/crates.io-index"
301
- checksum = "43c5703da9466b66a946814e1adf53ea2c90f10063b86290cc9eb67ce3478a20"
301
+ checksum = "a1dce859f0832a7d088c4f1119888ab94ef4b5d6795d1ce05afb7fe159d79f98"
302
302
  dependencies = [
303
303
  "find-msvc-tools",
304
304
  "shlex",
@@ -365,9 +365,9 @@ dependencies = [
365
365
 
366
366
  [[package]]
367
367
  name = "const-hex"
368
- version = "1.18.1"
368
+ version = "1.19.0"
369
369
  source = "registry+https://github.com/rust-lang/crates.io-index"
370
- checksum = "531185e432bb31db1ecda541e9e7ab21468d4d844ad7505e0546a49b4945d49b"
370
+ checksum = "20d9a563d167a9cce0f94153382b33cb6eded6dfabff03c69ad65a28ea1514e0"
371
371
  dependencies = [
372
372
  "cfg-if",
373
373
  "cpufeatures 0.2.17",
@@ -522,9 +522,9 @@ dependencies = [
522
522
 
523
523
  [[package]]
524
524
  name = "digest"
525
- version = "0.11.2"
525
+ version = "0.11.3"
526
526
  source = "registry+https://github.com/rust-lang/crates.io-index"
527
- checksum = "4850db49bf08e663084f7fb5c87d202ef91a3907271aff24a94eb97ff039153c"
527
+ checksum = "f1dd6dbb5841937940781866fa1281a1ff7bd3bf827091440879f9994983d5c2"
528
528
  dependencies = [
529
529
  "block-buffer 0.12.0",
530
530
  "const-oid",
@@ -808,9 +808,9 @@ dependencies = [
808
808
 
809
809
  [[package]]
810
810
  name = "h2"
811
- version = "0.4.13"
811
+ version = "0.4.14"
812
812
  source = "registry+https://github.com/rust-lang/crates.io-index"
813
- checksum = "2f44da3a8150a6703ed5d34e164b875fd14c2cdab9af1252a9a1020bde2bdc54"
813
+ checksum = "171fefbc92fe4a4de27e0698d6a5b392d6a0e333506bc49133760b3bcf948733"
814
814
  dependencies = [
815
815
  "atomic-waker",
816
816
  "bytes",
@@ -928,9 +928,9 @@ checksum = "135b12329e5e3ce057a9f972339ea52bc954fe1e9358ef27f95e89716fbc5424"
928
928
 
929
929
  [[package]]
930
930
  name = "hybrid-array"
931
- version = "0.4.10"
931
+ version = "0.4.11"
932
932
  source = "registry+https://github.com/rust-lang/crates.io-index"
933
- checksum = "3944cf8cf766b40e2a1a333ee5e9b563f854d5fa49d6a8ca2764e97c6eddb214"
933
+ checksum = "08d46837a0ed51fe95bd3b05de33cd64a1ee88fc797477ca48446872504507c5"
934
934
  dependencies = [
935
935
  "typenum",
936
936
  ]
@@ -1124,9 +1124,9 @@ dependencies = [
1124
1124
 
1125
1125
  [[package]]
1126
1126
  name = "idna_adapter"
1127
- version = "1.2.1"
1127
+ version = "1.2.2"
1128
1128
  source = "registry+https://github.com/rust-lang/crates.io-index"
1129
- checksum = "3acae9609540aa318d1bc588455225fb2085b9ed0c4f6bd0d9d5bcd86f1a0344"
1129
+ checksum = "cb68373c0d6620ef8105e855e7745e18b0d00d3bdb07fb532e434244cdb9a714"
1130
1130
  dependencies = [
1131
1131
  "icu_normalizer",
1132
1132
  "icu_properties",
@@ -1173,16 +1173,6 @@ version = "2.12.0"
1173
1173
  source = "registry+https://github.com/rust-lang/crates.io-index"
1174
1174
  checksum = "d98f6fed1fde3f8c21bc40a1abb88dd75e67924f9cffc3ef95607bad8017f8e2"
1175
1175
 
1176
- [[package]]
1177
- name = "iri-string"
1178
- version = "0.7.12"
1179
- source = "registry+https://github.com/rust-lang/crates.io-index"
1180
- checksum = "25e659a4bb38e810ebc252e53b5814ff908a8c58c2a9ce2fae1bbec24cbf4e20"
1181
- dependencies = [
1182
- "memchr",
1183
- "serde",
1184
- ]
1185
-
1186
1176
  [[package]]
1187
1177
  name = "itertools"
1188
1178
  version = "0.13.0"
@@ -1209,9 +1199,9 @@ checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682"
1209
1199
 
1210
1200
  [[package]]
1211
1201
  name = "js-sys"
1212
- version = "0.3.95"
1202
+ version = "0.3.98"
1213
1203
  source = "registry+https://github.com/rust-lang/crates.io-index"
1214
- checksum = "2964e92d1d9dc3364cae4d718d93f227e3abb088e747d92e0395bfdedf1c12ca"
1204
+ checksum = "67df7112613f8bfd9150013a0314e196f4800d3201ae742489d999db2f979f08"
1215
1205
  dependencies = [
1216
1206
  "cfg-if",
1217
1207
  "futures-util",
@@ -1233,9 +1223,9 @@ checksum = "09edd9e8b54e49e587e4f6295a7d29c3ea94d469cb40ab8ca70b288248a81db2"
1233
1223
 
1234
1224
  [[package]]
1235
1225
  name = "libc"
1236
- version = "0.2.185"
1226
+ version = "0.2.186"
1237
1227
  source = "registry+https://github.com/rust-lang/crates.io-index"
1238
- checksum = "52ff2c0fe9bc6cb6b14a0592c2ff4fa9ceb83eea9db979b0487cd054946a2b8f"
1228
+ checksum = "68ab91017fe16c622486840e4c83c9a37afeff978bd239b5293d61ece587de66"
1239
1229
 
1240
1230
  [[package]]
1241
1231
  name = "libloading"
@@ -1247,6 +1237,15 @@ dependencies = [
1247
1237
  "windows-link",
1248
1238
  ]
1249
1239
 
1240
+ [[package]]
1241
+ name = "libmimalloc-sys"
1242
+ version = "0.1.47"
1243
+ source = "registry+https://github.com/rust-lang/crates.io-index"
1244
+ checksum = "2d1eacfa31c33ec25e873c136ba5669f00f9866d0688bea7be4d3f7e43067df6"
1245
+ dependencies = [
1246
+ "cc",
1247
+ ]
1248
+
1250
1249
  [[package]]
1251
1250
  name = "libredox"
1252
1251
  version = "0.1.16"
@@ -1342,6 +1341,15 @@ version = "2.8.0"
1342
1341
  source = "registry+https://github.com/rust-lang/crates.io-index"
1343
1342
  checksum = "f8ca58f447f06ed17d5fc4043ce1b10dd205e060fb3ce5b979b8ed8e59ff3f79"
1344
1343
 
1344
+ [[package]]
1345
+ name = "mimalloc"
1346
+ version = "0.1.50"
1347
+ source = "registry+https://github.com/rust-lang/crates.io-index"
1348
+ checksum = "b3627c4272df786b9260cabaa46aec1d59c93ede723d4c3ef646c503816b0640"
1349
+ dependencies = [
1350
+ "libmimalloc-sys",
1351
+ ]
1352
+
1345
1353
  [[package]]
1346
1354
  name = "mime"
1347
1355
  version = "0.3.17"
@@ -1572,18 +1580,18 @@ checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220"
1572
1580
 
1573
1581
  [[package]]
1574
1582
  name = "pin-project"
1575
- version = "1.1.11"
1583
+ version = "1.1.12"
1576
1584
  source = "registry+https://github.com/rust-lang/crates.io-index"
1577
- checksum = "f1749c7ed4bcaf4c3d0a3efc28538844fb29bcdd7d2b67b2be7e20ba861ff517"
1585
+ checksum = "cbf0d9e68100b3a7989b4901972f265cd542e560a3a8a724e1e20322f4d06ce9"
1578
1586
  dependencies = [
1579
1587
  "pin-project-internal",
1580
1588
  ]
1581
1589
 
1582
1590
  [[package]]
1583
1591
  name = "pin-project-internal"
1584
- version = "1.1.11"
1592
+ version = "1.1.12"
1585
1593
  source = "registry+https://github.com/rust-lang/crates.io-index"
1586
- checksum = "d9b20ed30f105399776b9c883e68e536ef602a16ae6f596d2c473591d6ad64c6"
1594
+ checksum = "a990e22f43e84855daf260dded30524ef4a9021cc7541c26540500a50b624389"
1587
1595
  dependencies = [
1588
1596
  "proc-macro2",
1589
1597
  "quote",
@@ -1700,14 +1708,15 @@ dependencies = [
1700
1708
  "educe",
1701
1709
  "futures",
1702
1710
  "magnus",
1711
+ "mimalloc",
1703
1712
  "opentelemetry",
1704
- "prosody 0.1.2",
1713
+ "prosody 0.3.0",
1705
1714
  "rb-sys",
1706
1715
  "serde",
1707
1716
  "serde-untagged",
1717
+ "serde_json",
1708
1718
  "serde_magnus",
1709
1719
  "thiserror",
1710
- "tikv-jemallocator",
1711
1720
  "tokio",
1712
1721
  "tokio-stream",
1713
1722
  "tracing",
@@ -1717,9 +1726,9 @@ dependencies = [
1717
1726
 
1718
1727
  [[package]]
1719
1728
  name = "prosody"
1720
- version = "0.1.2"
1729
+ version = "0.3.0"
1721
1730
  source = "registry+https://github.com/rust-lang/crates.io-index"
1722
- checksum = "31165aa5c07d25b92ab22a47d9400b20b1115f702b55c4c0325d51e285903b83"
1731
+ checksum = "3e207049a1b3a95610ed4a782c075cdd02dd22ec358b21eeacebcd931035cfcb"
1723
1732
  dependencies = [
1724
1733
  "ahash",
1725
1734
  "aho-corasick",
@@ -1920,18 +1929,18 @@ dependencies = [
1920
1929
 
1921
1930
  [[package]]
1922
1931
  name = "rb-sys"
1923
- version = "0.9.126"
1932
+ version = "0.9.128"
1924
1933
  source = "registry+https://github.com/rust-lang/crates.io-index"
1925
- checksum = "284799e73e899fe946fd77c7211b83bff61a1356e039ade7a2516a779e3212d0"
1934
+ checksum = "45ca28513560e56cfb79a62b1fce363c73af170a182024ce880c77ee9429920a"
1926
1935
  dependencies = [
1927
1936
  "rb-sys-build",
1928
1937
  ]
1929
1938
 
1930
1939
  [[package]]
1931
1940
  name = "rb-sys-build"
1932
- version = "0.9.126"
1941
+ version = "0.9.128"
1933
1942
  source = "registry+https://github.com/rust-lang/crates.io-index"
1934
- checksum = "855fc1ad8943d12c89ef12f9147f1cc531f5bf19fb744112fdd317bb6ee7b5c5"
1943
+ checksum = "ce04b2c55eff3a21aaa623fcc655d94373238e72cac6b3e1a3641ff31649f99a"
1935
1944
  dependencies = [
1936
1945
  "bindgen",
1937
1946
  "lazy_static",
@@ -2158,9 +2167,9 @@ checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49"
2158
2167
 
2159
2168
  [[package]]
2160
2169
  name = "scylla"
2161
- version = "1.5.0"
2170
+ version = "1.6.0"
2162
2171
  source = "registry+https://github.com/rust-lang/crates.io-index"
2163
- checksum = "7ab73aaea18839882f43c08bc6367dfd1d4e9d285a2ab6ac4335b9dc06b63c19"
2172
+ checksum = "e0f9ff6ccde6555beec62c794bbc8dcae08a15f2397e057a5978c199174be920"
2164
2173
  dependencies = [
2165
2174
  "arc-swap",
2166
2175
  "async-trait",
@@ -2183,9 +2192,9 @@ dependencies = [
2183
2192
 
2184
2193
  [[package]]
2185
2194
  name = "scylla-cql"
2186
- version = "1.5.0"
2195
+ version = "1.6.0"
2187
2196
  source = "registry+https://github.com/rust-lang/crates.io-index"
2188
- checksum = "87834c927e9336270725aac24fada6e86f9d14aa04a8c8f93223b002e86f3891"
2197
+ checksum = "1687853d084bd9debb38f326298aeb7ae9c9a336d6f22684f3579db785051efd"
2189
2198
  dependencies = [
2190
2199
  "byteorder",
2191
2200
  "bytes",
@@ -2203,9 +2212,9 @@ dependencies = [
2203
2212
 
2204
2213
  [[package]]
2205
2214
  name = "scylla-macros"
2206
- version = "1.5.0"
2215
+ version = "1.6.0"
2207
2216
  source = "registry+https://github.com/rust-lang/crates.io-index"
2208
- checksum = "ad97e5f7ccd8a1d41e631e361c9851c21b093e15ff5dcd08861f6ac83215d434"
2217
+ checksum = "619e45d49f95b355afa56840d9021c789eddf8c3a6bef8d4b82de0912097d578"
2209
2218
  dependencies = [
2210
2219
  "darling",
2211
2220
  "proc-macro2",
@@ -2348,7 +2357,7 @@ checksum = "446ba717509524cb3f22f17ecc096f10f4822d76ab5c0b9822c5f9c284e825f4"
2348
2357
  dependencies = [
2349
2358
  "cfg-if",
2350
2359
  "cpufeatures 0.3.0",
2351
- "digest 0.11.2",
2360
+ "digest 0.11.3",
2352
2361
  ]
2353
2362
 
2354
2363
  [[package]]
@@ -2529,26 +2538,6 @@ dependencies = [
2529
2538
  "cfg-if",
2530
2539
  ]
2531
2540
 
2532
- [[package]]
2533
- name = "tikv-jemalloc-sys"
2534
- version = "0.6.1+5.3.0-1-ge13ca993e8ccb9ba9847cc330696e02839f328f7"
2535
- source = "registry+https://github.com/rust-lang/crates.io-index"
2536
- checksum = "cd8aa5b2ab86a2cefa406d889139c162cbb230092f7d1d7cbc1716405d852a3b"
2537
- dependencies = [
2538
- "cc",
2539
- "libc",
2540
- ]
2541
-
2542
- [[package]]
2543
- name = "tikv-jemallocator"
2544
- version = "0.6.1"
2545
- source = "registry+https://github.com/rust-lang/crates.io-index"
2546
- checksum = "0359b4327f954e0567e69fb191cf1436617748813819c94b8cd4a431422d053a"
2547
- dependencies = [
2548
- "libc",
2549
- "tikv-jemalloc-sys",
2550
- ]
2551
-
2552
2541
  [[package]]
2553
2542
  name = "tinystr"
2554
2543
  version = "0.8.3"
@@ -2561,9 +2550,9 @@ dependencies = [
2561
2550
 
2562
2551
  [[package]]
2563
2552
  name = "tokio"
2564
- version = "1.52.1"
2553
+ version = "1.52.3"
2565
2554
  source = "registry+https://github.com/rust-lang/crates.io-index"
2566
- checksum = "b67dee974fe86fd92cc45b7a95fdd2f99a36a6d7b0d431a231178d3d670bbcc6"
2555
+ checksum = "8fc7f01b389ac15039e4dc9531aa973a135d7a4135281b12d7c1bc79fd57fffe"
2567
2556
  dependencies = [
2568
2557
  "bytes",
2569
2558
  "libc",
@@ -2644,9 +2633,9 @@ dependencies = [
2644
2633
 
2645
2634
  [[package]]
2646
2635
  name = "tonic"
2647
- version = "0.14.5"
2636
+ version = "0.14.6"
2648
2637
  source = "registry+https://github.com/rust-lang/crates.io-index"
2649
- checksum = "fec7c61a0695dc1887c1b53952990f3ad2e3a31453e1f49f10e75424943a93ec"
2638
+ checksum = "ac2a5518c70fa84342385732db33fb3f44bc4cc748936eb5833d2df34d6445ef"
2650
2639
  dependencies = [
2651
2640
  "async-trait",
2652
2641
  "base64",
@@ -2670,9 +2659,9 @@ dependencies = [
2670
2659
 
2671
2660
  [[package]]
2672
2661
  name = "tonic-prost"
2673
- version = "0.14.5"
2662
+ version = "0.14.6"
2674
2663
  source = "registry+https://github.com/rust-lang/crates.io-index"
2675
- checksum = "a55376a0bbaa4975a3f10d009ad763d8f4108f067c7c2e74f3001fb49778d309"
2664
+ checksum = "50849f68853be452acf590cde0b146665b8d507b3b8af17261df47e02c209ea0"
2676
2665
  dependencies = [
2677
2666
  "bytes",
2678
2667
  "prost",
@@ -2700,20 +2689,20 @@ dependencies = [
2700
2689
 
2701
2690
  [[package]]
2702
2691
  name = "tower-http"
2703
- version = "0.6.8"
2692
+ version = "0.6.10"
2704
2693
  source = "registry+https://github.com/rust-lang/crates.io-index"
2705
- checksum = "d4e6559d53cc268e5031cd8429d05415bc4cb4aefc4aa5d6cc35fbf5b924a1f8"
2694
+ checksum = "68d6fdd9f81c2819c9a8b0e0cd91660e7746a8e6ea2ba7c6b2b057985f6bcb51"
2706
2695
  dependencies = [
2707
2696
  "bitflags",
2708
2697
  "bytes",
2709
2698
  "futures-util",
2710
2699
  "http",
2711
2700
  "http-body",
2712
- "iri-string",
2713
2701
  "pin-project-lite",
2714
2702
  "tower",
2715
2703
  "tower-layer",
2716
2704
  "tower-service",
2705
+ "url",
2717
2706
  ]
2718
2707
 
2719
2708
  [[package]]
@@ -3008,9 +2997,9 @@ dependencies = [
3008
2997
 
3009
2998
  [[package]]
3010
2999
  name = "wasm-bindgen"
3011
- version = "0.2.118"
3000
+ version = "0.2.121"
3012
3001
  source = "registry+https://github.com/rust-lang/crates.io-index"
3013
- checksum = "0bf938a0bacb0469e83c1e148908bd7d5a6010354cf4fb73279b7447422e3a89"
3002
+ checksum = "49ace1d07c165b0864824eee619580c4689389afa9dc9ed3a4c75040d82e6790"
3014
3003
  dependencies = [
3015
3004
  "cfg-if",
3016
3005
  "once_cell",
@@ -3021,9 +3010,9 @@ dependencies = [
3021
3010
 
3022
3011
  [[package]]
3023
3012
  name = "wasm-bindgen-futures"
3024
- version = "0.4.68"
3013
+ version = "0.4.71"
3025
3014
  source = "registry+https://github.com/rust-lang/crates.io-index"
3026
- checksum = "f371d383f2fb139252e0bfac3b81b265689bf45b6874af544ffa4c975ac1ebf8"
3015
+ checksum = "96492d0d3ffba25305a7dc88720d250b1401d7edca02cc3bcd50633b424673b8"
3027
3016
  dependencies = [
3028
3017
  "js-sys",
3029
3018
  "wasm-bindgen",
@@ -3031,9 +3020,9 @@ dependencies = [
3031
3020
 
3032
3021
  [[package]]
3033
3022
  name = "wasm-bindgen-macro"
3034
- version = "0.2.118"
3023
+ version = "0.2.121"
3035
3024
  source = "registry+https://github.com/rust-lang/crates.io-index"
3036
- checksum = "eeff24f84126c0ec2db7a449f0c2ec963c6a49efe0698c4242929da037ca28ed"
3025
+ checksum = "8e68e6f4afd367a562002c05637acb8578ff2dea1943df76afb9e83d177c8578"
3037
3026
  dependencies = [
3038
3027
  "quote",
3039
3028
  "wasm-bindgen-macro-support",
@@ -3041,9 +3030,9 @@ dependencies = [
3041
3030
 
3042
3031
  [[package]]
3043
3032
  name = "wasm-bindgen-macro-support"
3044
- version = "0.2.118"
3033
+ version = "0.2.121"
3045
3034
  source = "registry+https://github.com/rust-lang/crates.io-index"
3046
- checksum = "9d08065faf983b2b80a79fd87d8254c409281cf7de75fc4b773019824196c904"
3035
+ checksum = "d95a9ec35c64b2a7cb35d3fead40c4238d0940c86d107136999567a4703259f2"
3047
3036
  dependencies = [
3048
3037
  "bumpalo",
3049
3038
  "proc-macro2",
@@ -3054,9 +3043,9 @@ dependencies = [
3054
3043
 
3055
3044
  [[package]]
3056
3045
  name = "wasm-bindgen-shared"
3057
- version = "0.2.118"
3046
+ version = "0.2.121"
3058
3047
  source = "registry+https://github.com/rust-lang/crates.io-index"
3059
- checksum = "5fd04d9e306f1907bd13c6361b5c6bfc7b3b3c095ed3f8a9246390f8dbdee129"
3048
+ checksum = "c4e0100b01e9f0d03189a92b96772a1fb998639d981193d7dbab487302513441"
3060
3049
  dependencies = [
3061
3050
  "unicode-ident",
3062
3051
  ]
@@ -3097,9 +3086,9 @@ dependencies = [
3097
3086
 
3098
3087
  [[package]]
3099
3088
  name = "web-sys"
3100
- version = "0.3.95"
3089
+ version = "0.3.98"
3101
3090
  source = "registry+https://github.com/rust-lang/crates.io-index"
3102
- checksum = "4f2dfbb17949fa2088e5d39408c48368947b86f7834484e87b73de55bc14d97d"
3091
+ checksum = "4b572dff8bcf38bad0fa19729c89bb5748b2b9b1d8be70cf90df697e3a8f32aa"
3103
3092
  dependencies = [
3104
3093
  "js-sys",
3105
3094
  "wasm-bindgen",
@@ -3117,9 +3106,9 @@ dependencies = [
3117
3106
 
3118
3107
  [[package]]
3119
3108
  name = "whoami"
3120
- version = "2.1.1"
3109
+ version = "2.1.2"
3121
3110
  source = "registry+https://github.com/rust-lang/crates.io-index"
3122
- checksum = "d6a5b12f9df4f978d2cfdb1bd3bac52433f44393342d7ee9c25f5a1c14c0f45d"
3111
+ checksum = "998767ef88740d1f5b0682a9c53c24431453923962269c2db68ee43788c5a40d"
3123
3112
  dependencies = [
3124
3113
  "libc",
3125
3114
  "libredox",
@@ -3302,9 +3291,9 @@ checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec"
3302
3291
 
3303
3292
  [[package]]
3304
3293
  name = "winnow"
3305
- version = "1.0.1"
3294
+ version = "1.0.2"
3306
3295
  source = "registry+https://github.com/rust-lang/crates.io-index"
3307
- checksum = "09dac053f1cd375980747450bfc7250c264eaae0583872e845c0c7cd578872b5"
3296
+ checksum = "2ee1708bef14716a11bae175f579062d4554d95be2c6829f518df847b7b3fdd0"
3308
3297
  dependencies = [
3309
3298
  "memchr",
3310
3299
  ]
data/Cargo.toml CHANGED
@@ -12,14 +12,15 @@ bumpalo = "3.19"
12
12
  educe = "0.6"
13
13
  futures = "0.3"
14
14
  magnus = { version = "0.8", default-features = false }
15
+ mimalloc = "0.1"
15
16
  opentelemetry = "0.31"
16
- prosody = { version = "0.1", features = ["libz-static"] }
17
+ prosody = { version = "0.3", features = ["libz-static"] }
17
18
  rb-sys = "0.9"
18
19
  serde = "1.0"
19
20
  serde-untagged = "0.1"
21
+ serde_json = "1.0"
20
22
  serde_magnus = "0.11"
21
23
  thiserror = "2.0"
22
- tikv-jemallocator = "0.6"
23
24
  tokio = "1.46"
24
25
  tokio-stream = "0.1"
25
26
  tracing = "0.1"
data/README.md CHANGED
@@ -335,7 +335,20 @@ PROSODY_STALL_THRESHOLD=15s # Default stall detection threshold
335
335
  4. Setting the threshold too low might cause false positives, while setting it too high could delay detection of actual
336
336
  issues.
337
337
  5. The probe server is only active when consuming messages (not for producer-only usage).
338
-
338
+ > [!NOTE]
339
+ > **Rails users:** Because prosody-rb is built on the async gem, handlers run on fibers rather than threads. Rails defaults ActiveSupport's isolation level to `:thread`, which causes ActiveRecord connections to be shared across fibers and produces errors like:
340
+ >
341
+ > ```
342
+ > ActiveRecord::StatementInvalid: Mysql2::Error: This connection is in use by: #<Fiber
343
+ > ```
344
+ >
345
+ > Set the isolation level to `:fiber` in `config/application.rb`:
346
+ >
347
+ > ```ruby
348
+ > config.active_support.isolation_level = :fiber
349
+ > ```
350
+
351
+ ### Client Stall State
339
352
  You can monitor the stall state programmatically using the client's methods:
340
353
 
341
354
  ```ruby
@@ -14,11 +14,13 @@ bumpalo = { workspace = true, features = ["collections"] }
14
14
  educe.workspace = true
15
15
  futures.workspace = true
16
16
  magnus = { workspace = true, default-features = false }
17
+ mimalloc = { workspace = true, features = ["local_dynamic_tls"] }
17
18
  opentelemetry.workspace = true
18
19
  prosody = { workspace = true }
19
20
  rb-sys.workspace = true
20
21
  serde = { workspace = true, features = ["derive"] }
21
22
  serde-untagged.workspace = true
23
+ serde_json.workspace = true
22
24
  serde_magnus.workspace = true
23
25
  thiserror.workspace = true
24
26
  tokio = { workspace = true, features = ["macros", "rt-multi-thread", "sync"] }
@@ -28,11 +30,5 @@ tracing-opentelemetry.workspace = true
28
30
  tracing-subscriber.workspace = true
29
31
 
30
32
 
31
- [target.'cfg(not(target_os = "windows"))'.dependencies]
32
- tikv-jemallocator = { workspace = true, features = [
33
- "disable_initial_exec_tls",
34
- ] }
35
-
36
-
37
33
  [lints]
38
34
  workspace = true
@@ -26,8 +26,8 @@ impl AsyncCallback {
26
26
  /// # Arguments
27
27
  ///
28
28
  /// * `queue` - A Ruby Queue object that will receive values from Rust
29
- /// * `bridge` - The bridge used to defer cleanup of the wrapped queue
30
- /// value onto the Ruby thread when the callback is dropped
29
+ /// * `bridge` - The bridge used to defer cleanup of the wrapped queue value
30
+ /// onto the Ruby thread when the callback is dropped
31
31
  pub fn from_queue(queue: Value, bridge: Bridge) -> Self {
32
32
  Self {
33
33
  queue: ThreadSafeValue::new(queue, bridge),
@@ -175,7 +175,8 @@ pub struct NativeConfiguration {
175
175
  /// Cache size for defer middleware.
176
176
  defer_cache_size: Option<u32>,
177
177
 
178
- /// Maximum number of deferred store entries kept in the write-through cache per Cassandra defer store.
178
+ /// Maximum number of deferred store entries kept in the write-through cache
179
+ /// per Cassandra defer store.
179
180
  defer_store_cache_size: Option<u32>,
180
181
 
181
182
  /// Timeout for Kafka seek operations (in seconds).
@@ -16,6 +16,7 @@ use crate::handler::RubyHandler;
16
16
  use crate::tracing_util::extract_opentelemetry_context;
17
17
  use crate::util::ensure_runtime_context;
18
18
  use crate::{BRIDGE, ROOT_MOD, id};
19
+ use educe::Educe;
19
20
  use magnus::value::ReprValue;
20
21
  use magnus::{Error, Module, Object, RClass, Ruby, StaticSymbol, Value, function, method};
21
22
  use opentelemetry::propagation::TextMapCompositePropagator;
@@ -37,10 +38,12 @@ mod config;
37
38
  /// This struct bridges Ruby applications with the Prosody messaging system,
38
39
  /// providing methods for sending messages to Kafka topics and subscribing to
39
40
  /// events with Ruby handlers.
40
- #[derive(Debug)]
41
+ #[derive(Educe)]
42
+ #[educe(Debug)]
41
43
  #[magnus::wrap(class = "Prosody::Client")]
42
44
  pub struct Client {
43
45
  /// The underlying Prosody client
46
+ #[educe(Debug(ignore))]
44
47
  inner: Arc<HighLevelClient<RubyHandler>>,
45
48
  /// Bridge for communicating between Rust and Ruby
46
49
  bridge: Bridge,
@@ -212,7 +215,7 @@ impl Client {
212
215
  this.bridge
213
216
  .wait_for(
214
217
  ruby,
215
- async move { client.send(topic.as_str().into(), &key, &value).await },
218
+ async move { client.send(topic.as_str().into(), &key, value).await },
216
219
  span,
217
220
  )?
218
221
  .map_err(|error| Error::new(ruby.exception_runtime_error(), format!("{error:#}")))
@@ -21,7 +21,7 @@ use serde_magnus::serialize;
21
21
  pub struct Message {
22
22
  /// The wrapped Prosody consumer message
23
23
  #[educe(Debug(ignore))]
24
- inner: ConsumerMessage,
24
+ inner: ConsumerMessage<serde_json::Value>,
25
25
  }
26
26
 
27
27
  impl Message {
@@ -105,13 +105,13 @@ impl Message {
105
105
  }
106
106
  }
107
107
 
108
- impl From<ConsumerMessage> for Message {
108
+ impl From<ConsumerMessage<serde_json::Value>> for Message {
109
109
  /// Creates a new Message wrapper from a Prosody `ConsumerMessage`.
110
110
  ///
111
111
  /// # Arguments
112
112
  ///
113
113
  /// * `value` - The Prosody `ConsumerMessage` to wrap
114
- fn from(value: ConsumerMessage) -> Self {
114
+ fn from(value: ConsumerMessage<serde_json::Value>) -> Self {
115
115
  Self { inner: value }
116
116
  }
117
117
  }
@@ -21,6 +21,7 @@ use futures::pin_mut;
21
21
  use magnus::value::ReprValue;
22
22
  use magnus::{Error, Ruby, Value};
23
23
  use opentelemetry::propagation::TextMapCompositePropagator;
24
+ use opentelemetry::trace::Status;
24
25
  use prosody::consumer::event_context::EventContext;
25
26
  use prosody::consumer::message::ConsumerMessage;
26
27
  use prosody::consumer::middleware::FallibleHandler;
@@ -33,6 +34,7 @@ use std::sync::Arc;
33
34
  use thiserror::Error;
34
35
  use tokio::select;
35
36
  use tracing::{Instrument, info_span};
37
+ use tracing_opentelemetry::OpenTelemetrySpanExt;
36
38
 
37
39
  mod context;
38
40
  mod message;
@@ -85,6 +87,8 @@ impl RubyHandler {
85
87
 
86
88
  impl FallibleHandler for RubyHandler {
87
89
  type Error = RubyHandlerError;
90
+ type Output = ();
91
+ type Payload = serde_json::Value;
88
92
 
89
93
  /// Processes a Kafka message by dispatching it to the Ruby handler.
90
94
  ///
@@ -109,7 +113,7 @@ impl FallibleHandler for RubyHandler {
109
113
  async fn on_message<C>(
110
114
  &self,
111
115
  context: C,
112
- message: ConsumerMessage,
116
+ message: ConsumerMessage<Self::Payload>,
113
117
  _demand_type: DemandType,
114
118
  ) -> Result<(), Self::Error>
115
119
  where
@@ -179,11 +183,13 @@ impl FallibleHandler for RubyHandler {
179
183
  // Wait for either task completion or shutdown signal
180
184
  select! {
181
185
  result = &mut result_future => {
182
- result?;
186
+ result.inspect_err(|e| cloned_span.set_status(Status::error(e.to_string())))?;
183
187
  }
184
188
  () = cancel_future => {
185
- // If cancellation requested, cancel the task and wait for it to complete
186
- task_handle.cancellation_token.cancel(&self.bridge).await?;
189
+ // A cancel() failure is a genuine bridge error; mark the span.
190
+ // The subsequent result_future error is expected cancellation, not a handler bug.
191
+ task_handle.cancellation_token.cancel(&self.bridge).await
192
+ .inspect_err(|e| cloned_span.set_status(Status::error(e.to_string())))?;
187
193
  result_future.await?;
188
194
  }
189
195
  }
@@ -262,11 +268,13 @@ impl FallibleHandler for RubyHandler {
262
268
  // Wait for either task completion or shutdown signal
263
269
  select! {
264
270
  result = &mut result_future => {
265
- result?;
271
+ result.inspect_err(|e| cloned_span.set_status(Status::error(e.to_string())))?;
266
272
  }
267
273
  () = cancel_future => {
268
- // If cancellation requested, cancel the task and wait for it to complete
269
- task_handle.cancellation_token.cancel(&self.bridge).await?;
274
+ // A cancel() failure is a genuine bridge error; mark the span.
275
+ // The subsequent result_future error is expected cancellation, not a handler bug.
276
+ task_handle.cancellation_token.cancel(&self.bridge).await
277
+ .inspect_err(|e| cloned_span.set_status(Status::error(e.to_string())))?;
270
278
  result_future.await?;
271
279
  }
272
280
  }
@@ -15,9 +15,8 @@
15
15
  use crate::bridge::Bridge;
16
16
  use magnus::value::Lazy;
17
17
  use magnus::{Error, RModule, Ruby};
18
+ use mimalloc::MiMalloc;
18
19
  use std::sync::{LazyLock, OnceLock};
19
- #[cfg(not(target_os = "windows"))]
20
- use tikv_jemallocator::Jemalloc;
21
20
  use tokio::runtime::Runtime;
22
21
 
23
22
  mod admin;
@@ -30,9 +29,8 @@ mod scheduler;
30
29
  mod tracing_util;
31
30
  mod util;
32
31
 
33
- #[cfg(not(target_os = "windows"))]
34
32
  #[global_allocator]
35
- static GLOBAL: Jemalloc = Jemalloc;
33
+ static GLOBAL: MiMalloc = MiMalloc;
36
34
 
37
35
  /// Global instance of the Ruby-Rust communication bridge.
38
36
  /// Initialized during extension startup and used throughout the library.
@@ -26,8 +26,8 @@ impl CancellationToken {
26
26
  /// # Arguments
27
27
  ///
28
28
  /// * `token` - A Ruby value that responds to the `cancel` method
29
- /// * `bridge` - The bridge used to defer cleanup of the wrapped token
30
- /// value onto the Ruby thread when the token is dropped
29
+ /// * `bridge` - The bridge used to defer cleanup of the wrapped token value
30
+ /// onto the Ruby thread when the token is dropped
31
31
  pub fn new(token: Value, bridge: Bridge) -> Self {
32
32
  Self {
33
33
  token: ThreadSafeValue::new(token, bridge),
@@ -6,5 +6,5 @@ module Prosody
6
6
  # This version number follows semantic versioning and is used by the
7
7
  # gem system to identify the library version. It should be updated
8
8
  # according to semver guidelines when making releases.
9
- VERSION = "0.1.2"
9
+ VERSION = "0.2.1"
10
10
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: prosody
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joshua Griffith
@@ -43,14 +43,14 @@ dependencies:
43
43
  requirements:
44
44
  - - "~>"
45
45
  - !ruby/object:Gem::Version
46
- version: 0.9.126
46
+ version: 0.9.128
47
47
  type: :runtime
48
48
  prerelease: false
49
49
  version_requirements: !ruby/object:Gem::Requirement
50
50
  requirements:
51
51
  - - "~>"
52
52
  - !ruby/object:Gem::Version
53
- version: 0.9.126
53
+ version: 0.9.128
54
54
  - !ruby/object:Gem::Dependency
55
55
  name: async-rspec
56
56
  requirement: !ruby/object:Gem::Requirement