@temporalio/core-bridge 0.21.0 → 0.21.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.
- package/Cargo.lock +136 -127
- package/package.json +2 -2
- package/releases/aarch64-apple-darwin/index.node +0 -0
- package/releases/aarch64-unknown-linux-gnu/index.node +0 -0
- package/releases/x86_64-apple-darwin/index.node +0 -0
- package/releases/x86_64-pc-windows-msvc/index.node +0 -0
- package/releases/x86_64-unknown-linux-gnu/index.node +0 -0
- package/sdk-core/core/src/abstractions.rs +10 -3
- package/sdk-core/core/src/core_tests/queries.rs +54 -17
- package/sdk-core/core/src/core_tests/workflow_tasks.rs +0 -32
- package/sdk-core/core/src/worker/mod.rs +4 -3
- package/sdk-core/core/src/workflow/machines/workflow_machines.rs +9 -2
- package/sdk-core/core/src/workflow/mod.rs +5 -2
- package/sdk-core/core/src/workflow/workflow_tasks/mod.rs +19 -7
- package/sdk-core/sdk-core-protos/src/history_info.rs +3 -7
package/Cargo.lock
CHANGED
|
@@ -33,9 +33,9 @@ dependencies = [
|
|
|
33
33
|
|
|
34
34
|
[[package]]
|
|
35
35
|
name = "anyhow"
|
|
36
|
-
version = "1.0.
|
|
36
|
+
version = "1.0.56"
|
|
37
37
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
38
|
-
checksum = "
|
|
38
|
+
checksum = "4361135be9122e0870de935d7c439aef945b9f9ddd4199a553b5270b49c82a27"
|
|
39
39
|
|
|
40
40
|
[[package]]
|
|
41
41
|
name = "arc-swap"
|
|
@@ -45,9 +45,9 @@ checksum = "c5d78ce20460b82d3fa150275ed9d55e21064fc7951177baacf86a145c4a4b1f"
|
|
|
45
45
|
|
|
46
46
|
[[package]]
|
|
47
47
|
name = "async-stream"
|
|
48
|
-
version = "0.3.
|
|
48
|
+
version = "0.3.3"
|
|
49
49
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
50
|
-
checksum = "
|
|
50
|
+
checksum = "dad5c83079eae9969be7fadefe640a1c566901f05ff91ab221de4b6f68d9507e"
|
|
51
51
|
dependencies = [
|
|
52
52
|
"async-stream-impl",
|
|
53
53
|
"futures-core",
|
|
@@ -55,9 +55,9 @@ dependencies = [
|
|
|
55
55
|
|
|
56
56
|
[[package]]
|
|
57
57
|
name = "async-stream-impl"
|
|
58
|
-
version = "0.3.
|
|
58
|
+
version = "0.3.3"
|
|
59
59
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
60
|
-
checksum = "
|
|
60
|
+
checksum = "10f203db73a71dfa2fb6dd22763990fa26f3d2625a6da2da900d23b87d26be27"
|
|
61
61
|
dependencies = [
|
|
62
62
|
"proc-macro2",
|
|
63
63
|
"quote",
|
|
@@ -66,9 +66,9 @@ dependencies = [
|
|
|
66
66
|
|
|
67
67
|
[[package]]
|
|
68
68
|
name = "async-trait"
|
|
69
|
-
version = "0.1.
|
|
69
|
+
version = "0.1.53"
|
|
70
70
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
71
|
-
checksum = "
|
|
71
|
+
checksum = "ed6aa3524a2dfcf9fe180c51eae2b58738348d819517ceadf95789c51fff7600"
|
|
72
72
|
dependencies = [
|
|
73
73
|
"proc-macro2",
|
|
74
74
|
"quote",
|
|
@@ -124,9 +124,9 @@ checksum = "c1db59621ec70f09c5e9b597b220c7a2b43611f4710dc03ceb8748637775692c"
|
|
|
124
124
|
|
|
125
125
|
[[package]]
|
|
126
126
|
name = "cc"
|
|
127
|
-
version = "1.0.
|
|
127
|
+
version = "1.0.73"
|
|
128
128
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
129
|
-
checksum = "
|
|
129
|
+
checksum = "2fff2a6927b3bb87f9595d67196a70493f627687a71d87a0d692242c33f58c11"
|
|
130
130
|
|
|
131
131
|
[[package]]
|
|
132
132
|
name = "cfg-if"
|
|
@@ -172,9 +172,9 @@ dependencies = [
|
|
|
172
172
|
|
|
173
173
|
[[package]]
|
|
174
174
|
name = "crossbeam-channel"
|
|
175
|
-
version = "0.5.
|
|
175
|
+
version = "0.5.4"
|
|
176
176
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
177
|
-
checksum = "
|
|
177
|
+
checksum = "5aaa7bd5fb665c6864b5f963dd9097905c54125909c7aa94c9e18507cdbe6c53"
|
|
178
178
|
dependencies = [
|
|
179
179
|
"cfg-if",
|
|
180
180
|
"crossbeam-utils",
|
|
@@ -193,10 +193,11 @@ dependencies = [
|
|
|
193
193
|
|
|
194
194
|
[[package]]
|
|
195
195
|
name = "crossbeam-epoch"
|
|
196
|
-
version = "0.9.
|
|
196
|
+
version = "0.9.8"
|
|
197
197
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
198
|
-
checksum = "
|
|
198
|
+
checksum = "1145cf131a2c6ba0615079ab6a638f7e1973ac9c2634fcbeaaad6114246efe8c"
|
|
199
199
|
dependencies = [
|
|
200
|
+
"autocfg",
|
|
200
201
|
"cfg-if",
|
|
201
202
|
"crossbeam-utils",
|
|
202
203
|
"lazy_static",
|
|
@@ -206,9 +207,9 @@ dependencies = [
|
|
|
206
207
|
|
|
207
208
|
[[package]]
|
|
208
209
|
name = "crossbeam-queue"
|
|
209
|
-
version = "0.3.
|
|
210
|
+
version = "0.3.5"
|
|
210
211
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
211
|
-
checksum = "
|
|
212
|
+
checksum = "1f25d8400f4a7a5778f0e4e52384a48cbd9b5c495d110786187fc750075277a2"
|
|
212
213
|
dependencies = [
|
|
213
214
|
"cfg-if",
|
|
214
215
|
"crossbeam-utils",
|
|
@@ -216,9 +217,9 @@ dependencies = [
|
|
|
216
217
|
|
|
217
218
|
[[package]]
|
|
218
219
|
name = "crossbeam-utils"
|
|
219
|
-
version = "0.8.
|
|
220
|
+
version = "0.8.8"
|
|
220
221
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
221
|
-
checksum = "
|
|
222
|
+
checksum = "0bf124c720b7686e3c2663cf54062ab0f68a88af2fb6a030e87e30bf721fcb38"
|
|
222
223
|
dependencies = [
|
|
223
224
|
"cfg-if",
|
|
224
225
|
"lazy_static",
|
|
@@ -232,9 +233,9 @@ checksum = "697c714f50560202b1f4e2e09cd50a421881c83e9025db75d15f276616f04f40"
|
|
|
232
233
|
|
|
233
234
|
[[package]]
|
|
234
235
|
name = "darling"
|
|
235
|
-
version = "0.
|
|
236
|
+
version = "0.14.0"
|
|
236
237
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
237
|
-
checksum = "
|
|
238
|
+
checksum = "f1a5d2e8b5a94b2261efb20e99a01255b9c5293797d69bbf04600567b2f9b8d7"
|
|
238
239
|
dependencies = [
|
|
239
240
|
"darling_core",
|
|
240
241
|
"darling_macro",
|
|
@@ -242,9 +243,9 @@ dependencies = [
|
|
|
242
243
|
|
|
243
244
|
[[package]]
|
|
244
245
|
name = "darling_core"
|
|
245
|
-
version = "0.
|
|
246
|
+
version = "0.14.0"
|
|
246
247
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
247
|
-
checksum = "
|
|
248
|
+
checksum = "8f1c7d56716be82d9c6adb967cfe700955179ea88806e898483dad6987330a54"
|
|
248
249
|
dependencies = [
|
|
249
250
|
"fnv",
|
|
250
251
|
"ident_case",
|
|
@@ -256,9 +257,9 @@ dependencies = [
|
|
|
256
257
|
|
|
257
258
|
[[package]]
|
|
258
259
|
name = "darling_macro"
|
|
259
|
-
version = "0.
|
|
260
|
+
version = "0.14.0"
|
|
260
261
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
261
|
-
checksum = "
|
|
262
|
+
checksum = "64dd7e5a75a00cb6799ae9fbbfc3bba0134def6579a9e27564e72c839c837bed"
|
|
262
263
|
dependencies = [
|
|
263
264
|
"darling_core",
|
|
264
265
|
"quote",
|
|
@@ -277,9 +278,9 @@ dependencies = [
|
|
|
277
278
|
|
|
278
279
|
[[package]]
|
|
279
280
|
name = "dashmap"
|
|
280
|
-
version = "5.
|
|
281
|
+
version = "5.2.0"
|
|
281
282
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
282
|
-
checksum = "
|
|
283
|
+
checksum = "4c8858831f7781322e539ea39e72449c46b059638250c14344fec8d0aa6e539c"
|
|
283
284
|
dependencies = [
|
|
284
285
|
"cfg-if",
|
|
285
286
|
"num_cpus",
|
|
@@ -288,18 +289,18 @@ dependencies = [
|
|
|
288
289
|
|
|
289
290
|
[[package]]
|
|
290
291
|
name = "derive_builder"
|
|
291
|
-
version = "0.11.
|
|
292
|
+
version = "0.11.2"
|
|
292
293
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
293
|
-
checksum = "
|
|
294
|
+
checksum = "d07adf7be193b71cc36b193d0f5fe60b918a3a9db4dad0449f57bcfd519704a3"
|
|
294
295
|
dependencies = [
|
|
295
296
|
"derive_builder_macro",
|
|
296
297
|
]
|
|
297
298
|
|
|
298
299
|
[[package]]
|
|
299
300
|
name = "derive_builder_core"
|
|
300
|
-
version = "0.11.
|
|
301
|
+
version = "0.11.2"
|
|
301
302
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
302
|
-
checksum = "
|
|
303
|
+
checksum = "1f91d4cfa921f1c05904dc3c57b4a32c38aed3340cce209f3a6fd1478babafc4"
|
|
303
304
|
dependencies = [
|
|
304
305
|
"darling",
|
|
305
306
|
"proc-macro2",
|
|
@@ -309,9 +310,9 @@ dependencies = [
|
|
|
309
310
|
|
|
310
311
|
[[package]]
|
|
311
312
|
name = "derive_builder_macro"
|
|
312
|
-
version = "0.11.
|
|
313
|
+
version = "0.11.2"
|
|
313
314
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
314
|
-
checksum = "
|
|
315
|
+
checksum = "8f0314b72bed045f3a68671b3c86328386762c93f82d98c65c3cb5e5f573dd68"
|
|
315
316
|
dependencies = [
|
|
316
317
|
"derive_builder_core",
|
|
317
318
|
"syn",
|
|
@@ -402,9 +403,9 @@ dependencies = [
|
|
|
402
403
|
|
|
403
404
|
[[package]]
|
|
404
405
|
name = "fragile"
|
|
405
|
-
version = "1.
|
|
406
|
+
version = "1.2.0"
|
|
406
407
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
407
|
-
checksum = "
|
|
408
|
+
checksum = "e9d758e60b45e8d749c89c1b389ad8aee550f86aa12e2b9298b546dda7a82ab1"
|
|
408
409
|
|
|
409
410
|
[[package]]
|
|
410
411
|
name = "futures"
|
|
@@ -508,20 +509,20 @@ dependencies = [
|
|
|
508
509
|
|
|
509
510
|
[[package]]
|
|
510
511
|
name = "getrandom"
|
|
511
|
-
version = "0.2.
|
|
512
|
+
version = "0.2.6"
|
|
512
513
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
513
|
-
checksum = "
|
|
514
|
+
checksum = "9be70c98951c83b8d2f8f60d7065fa6d5146873094452a1008da8c2f1e4205ad"
|
|
514
515
|
dependencies = [
|
|
515
516
|
"cfg-if",
|
|
516
517
|
"libc",
|
|
517
|
-
"wasi",
|
|
518
|
+
"wasi 0.10.2+wasi-snapshot-preview1",
|
|
518
519
|
]
|
|
519
520
|
|
|
520
521
|
[[package]]
|
|
521
522
|
name = "h2"
|
|
522
|
-
version = "0.3.
|
|
523
|
+
version = "0.3.13"
|
|
523
524
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
524
|
-
checksum = "
|
|
525
|
+
checksum = "37a82c6d637fc9515a4694bbf1cb2457b79d81ce52b3108bdeea58b07dd34a57"
|
|
525
526
|
dependencies = [
|
|
526
527
|
"bytes",
|
|
527
528
|
"fnv",
|
|
@@ -532,7 +533,7 @@ dependencies = [
|
|
|
532
533
|
"indexmap",
|
|
533
534
|
"slab",
|
|
534
535
|
"tokio",
|
|
535
|
-
"tokio-util 0.
|
|
536
|
+
"tokio-util 0.7.1",
|
|
536
537
|
"tracing",
|
|
537
538
|
]
|
|
538
539
|
|
|
@@ -587,9 +588,9 @@ dependencies = [
|
|
|
587
588
|
|
|
588
589
|
[[package]]
|
|
589
590
|
name = "httparse"
|
|
590
|
-
version = "1.
|
|
591
|
+
version = "1.7.0"
|
|
591
592
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
592
|
-
checksum = "
|
|
593
|
+
checksum = "6330e8a36bd8c859f3fa6d9382911fbb7147ec39807f63b923933a247240b9ba"
|
|
593
594
|
|
|
594
595
|
[[package]]
|
|
595
596
|
name = "httpdate"
|
|
@@ -599,9 +600,9 @@ checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421"
|
|
|
599
600
|
|
|
600
601
|
[[package]]
|
|
601
602
|
name = "hyper"
|
|
602
|
-
version = "0.14.
|
|
603
|
+
version = "0.14.18"
|
|
603
604
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
604
|
-
checksum = "
|
|
605
|
+
checksum = "b26ae0a80afebe130861d90abf98e3814a4f28a4c6ffeb5ab8ebb2be311e0ef2"
|
|
605
606
|
dependencies = [
|
|
606
607
|
"bytes",
|
|
607
608
|
"futures-channel",
|
|
@@ -652,9 +653,9 @@ dependencies = [
|
|
|
652
653
|
|
|
653
654
|
[[package]]
|
|
654
655
|
name = "indexmap"
|
|
655
|
-
version = "1.8.
|
|
656
|
+
version = "1.8.1"
|
|
656
657
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
657
|
-
checksum = "
|
|
658
|
+
checksum = "0f647032dfaa1f8b6dc29bd3edb7bbef4861b8b8007ebb118d6db284fd59f6ee"
|
|
658
659
|
dependencies = [
|
|
659
660
|
"autocfg",
|
|
660
661
|
"hashbrown",
|
|
@@ -686,9 +687,9 @@ checksum = "1aab8fc367588b89dcee83ab0fd66b72b50b72fa1904d7095045ace2b0c81c35"
|
|
|
686
687
|
|
|
687
688
|
[[package]]
|
|
688
689
|
name = "js-sys"
|
|
689
|
-
version = "0.3.
|
|
690
|
+
version = "0.3.57"
|
|
690
691
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
691
|
-
checksum = "
|
|
692
|
+
checksum = "671a26f820db17c2a2750743f1dd03bafd15b98c9f30c7c2628c024c05d73397"
|
|
692
693
|
dependencies = [
|
|
693
694
|
"wasm-bindgen",
|
|
694
695
|
]
|
|
@@ -701,9 +702,9 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646"
|
|
|
701
702
|
|
|
702
703
|
[[package]]
|
|
703
704
|
name = "libc"
|
|
704
|
-
version = "0.2.
|
|
705
|
+
version = "0.2.124"
|
|
705
706
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
706
|
-
checksum = "
|
|
707
|
+
checksum = "21a41fed9d98f27ab1c6d161da622a4fa35e8a54a8adc24bbf3ddd0ef70b0e50"
|
|
707
708
|
|
|
708
709
|
[[package]]
|
|
709
710
|
name = "libloading"
|
|
@@ -717,27 +718,28 @@ dependencies = [
|
|
|
717
718
|
|
|
718
719
|
[[package]]
|
|
719
720
|
name = "lock_api"
|
|
720
|
-
version = "0.4.
|
|
721
|
+
version = "0.4.7"
|
|
721
722
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
722
|
-
checksum = "
|
|
723
|
+
checksum = "327fa5b6a6940e4699ec49a9beae1ea4845c6bab9314e4f84ac68742139d8c53"
|
|
723
724
|
dependencies = [
|
|
725
|
+
"autocfg",
|
|
724
726
|
"scopeguard",
|
|
725
727
|
]
|
|
726
728
|
|
|
727
729
|
[[package]]
|
|
728
730
|
name = "log"
|
|
729
|
-
version = "0.4.
|
|
731
|
+
version = "0.4.16"
|
|
730
732
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
731
|
-
checksum = "
|
|
733
|
+
checksum = "6389c490849ff5bc16be905ae24bc913a9c8892e19b2341dbc175e14c341c2b8"
|
|
732
734
|
dependencies = [
|
|
733
735
|
"cfg-if",
|
|
734
736
|
]
|
|
735
737
|
|
|
736
738
|
[[package]]
|
|
737
739
|
name = "lru"
|
|
738
|
-
version = "0.7.
|
|
740
|
+
version = "0.7.5"
|
|
739
741
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
740
|
-
checksum = "
|
|
742
|
+
checksum = "32613e41de4c47ab04970c348ca7ae7382cf116625755af070b008a15516a889"
|
|
741
743
|
dependencies = [
|
|
742
744
|
"hashbrown",
|
|
743
745
|
]
|
|
@@ -774,14 +776,15 @@ dependencies = [
|
|
|
774
776
|
|
|
775
777
|
[[package]]
|
|
776
778
|
name = "mio"
|
|
777
|
-
version = "0.
|
|
779
|
+
version = "0.8.2"
|
|
778
780
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
779
|
-
checksum = "
|
|
781
|
+
checksum = "52da4364ffb0e4fe33a9841a98a3f3014fb964045ce4f7a45a398243c8d6b0c9"
|
|
780
782
|
dependencies = [
|
|
781
783
|
"libc",
|
|
782
784
|
"log",
|
|
783
785
|
"miow",
|
|
784
786
|
"ntapi",
|
|
787
|
+
"wasi 0.11.0+wasi-snapshot-preview1",
|
|
785
788
|
"winapi",
|
|
786
789
|
]
|
|
787
790
|
|
|
@@ -904,9 +907,9 @@ dependencies = [
|
|
|
904
907
|
|
|
905
908
|
[[package]]
|
|
906
909
|
name = "once_cell"
|
|
907
|
-
version = "1.
|
|
910
|
+
version = "1.10.0"
|
|
908
911
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
909
|
-
checksum = "
|
|
912
|
+
checksum = "87f3e037eac156d1775da914196f0f37741a274155e34a0b7e427c35d2a2ecb9"
|
|
910
913
|
|
|
911
914
|
[[package]]
|
|
912
915
|
name = "openssl-probe"
|
|
@@ -1001,7 +1004,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
|
1001
1004
|
checksum = "87f5ec2493a61ac0506c0f4199f99070cbe83857b0337006a30f3e6719b8ef58"
|
|
1002
1005
|
dependencies = [
|
|
1003
1006
|
"lock_api",
|
|
1004
|
-
"parking_lot_core 0.9.
|
|
1007
|
+
"parking_lot_core 0.9.2",
|
|
1005
1008
|
]
|
|
1006
1009
|
|
|
1007
1010
|
[[package]]
|
|
@@ -1020,9 +1023,9 @@ dependencies = [
|
|
|
1020
1023
|
|
|
1021
1024
|
[[package]]
|
|
1022
1025
|
name = "parking_lot_core"
|
|
1023
|
-
version = "0.9.
|
|
1026
|
+
version = "0.9.2"
|
|
1024
1027
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1025
|
-
checksum = "
|
|
1028
|
+
checksum = "995f667a6c822200b0433ac218e05582f0e2efa1b922a3fd2fbaadc5f87bab37"
|
|
1026
1029
|
dependencies = [
|
|
1027
1030
|
"cfg-if",
|
|
1028
1031
|
"libc",
|
|
@@ -1117,9 +1120,9 @@ dependencies = [
|
|
|
1117
1120
|
|
|
1118
1121
|
[[package]]
|
|
1119
1122
|
name = "proc-macro2"
|
|
1120
|
-
version = "1.0.
|
|
1123
|
+
version = "1.0.37"
|
|
1121
1124
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1122
|
-
checksum = "
|
|
1125
|
+
checksum = "ec757218438d5fda206afc041538b2f6d889286160d649a86a24d37e1235afd1"
|
|
1123
1126
|
dependencies = [
|
|
1124
1127
|
"unicode-xid",
|
|
1125
1128
|
]
|
|
@@ -1200,9 +1203,9 @@ checksum = "cf7e6d18738ecd0902d30d1ad232c9125985a3422929b16c65517b38adc14f96"
|
|
|
1200
1203
|
|
|
1201
1204
|
[[package]]
|
|
1202
1205
|
name = "quote"
|
|
1203
|
-
version = "1.0.
|
|
1206
|
+
version = "1.0.18"
|
|
1204
1207
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1205
|
-
checksum = "
|
|
1208
|
+
checksum = "a1feb54ed693b93a84e14094943b84b7c4eae204c512b7ccb95ab0c66d278ad1"
|
|
1206
1209
|
dependencies = [
|
|
1207
1210
|
"proc-macro2",
|
|
1208
1211
|
]
|
|
@@ -1239,18 +1242,18 @@ dependencies = [
|
|
|
1239
1242
|
|
|
1240
1243
|
[[package]]
|
|
1241
1244
|
name = "redox_syscall"
|
|
1242
|
-
version = "0.2.
|
|
1245
|
+
version = "0.2.13"
|
|
1243
1246
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1244
|
-
checksum = "
|
|
1247
|
+
checksum = "62f25bc4c7e55e0b0b7a1d43fb893f4fa1361d0abe38b9ce4f323c2adfe6ef42"
|
|
1245
1248
|
dependencies = [
|
|
1246
1249
|
"bitflags",
|
|
1247
1250
|
]
|
|
1248
1251
|
|
|
1249
1252
|
[[package]]
|
|
1250
1253
|
name = "regex"
|
|
1251
|
-
version = "1.5.
|
|
1254
|
+
version = "1.5.5"
|
|
1252
1255
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1253
|
-
checksum = "
|
|
1256
|
+
checksum = "1a11647b6b25ff05a515cb92c365cec08801e83423a235b51e231e1808747286"
|
|
1254
1257
|
dependencies = [
|
|
1255
1258
|
"aho-corasick",
|
|
1256
1259
|
"memchr",
|
|
@@ -1298,9 +1301,9 @@ dependencies = [
|
|
|
1298
1301
|
|
|
1299
1302
|
[[package]]
|
|
1300
1303
|
name = "ringbuf"
|
|
1301
|
-
version = "0.2.
|
|
1304
|
+
version = "0.2.8"
|
|
1302
1305
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1303
|
-
checksum = "
|
|
1306
|
+
checksum = "f65af18d50f789e74aaf23bbb3f65dcd22a3cb6e029b5bced149f6bd57c5c2a2"
|
|
1304
1307
|
dependencies = [
|
|
1305
1308
|
"cache-padded",
|
|
1306
1309
|
]
|
|
@@ -1311,7 +1314,7 @@ version = "0.4.0"
|
|
|
1311
1314
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1312
1315
|
checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366"
|
|
1313
1316
|
dependencies = [
|
|
1314
|
-
"semver 1.0.
|
|
1317
|
+
"semver 1.0.7",
|
|
1315
1318
|
]
|
|
1316
1319
|
|
|
1317
1320
|
[[package]]
|
|
@@ -1428,9 +1431,9 @@ dependencies = [
|
|
|
1428
1431
|
|
|
1429
1432
|
[[package]]
|
|
1430
1433
|
name = "semver"
|
|
1431
|
-
version = "1.0.
|
|
1434
|
+
version = "1.0.7"
|
|
1432
1435
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1433
|
-
checksum = "
|
|
1436
|
+
checksum = "d65bd28f48be7196d222d95b9243287f48d27aca604e08497513019ff0502cc4"
|
|
1434
1437
|
|
|
1435
1438
|
[[package]]
|
|
1436
1439
|
name = "semver-parser"
|
|
@@ -1495,9 +1498,9 @@ checksum = "7bd3e3206899af3f8b12af284fafc038cc1dc2b41d1b89dd17297221c5d225de"
|
|
|
1495
1498
|
|
|
1496
1499
|
[[package]]
|
|
1497
1500
|
name = "slab"
|
|
1498
|
-
version = "0.4.
|
|
1501
|
+
version = "0.4.6"
|
|
1499
1502
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1500
|
-
checksum = "
|
|
1503
|
+
checksum = "eb703cfe953bccee95685111adeedb76fabe4e97549a58d16f03ea7b9367bb32"
|
|
1501
1504
|
|
|
1502
1505
|
[[package]]
|
|
1503
1506
|
name = "slotmap"
|
|
@@ -1538,9 +1541,9 @@ checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623"
|
|
|
1538
1541
|
|
|
1539
1542
|
[[package]]
|
|
1540
1543
|
name = "syn"
|
|
1541
|
-
version = "1.0.
|
|
1544
|
+
version = "1.0.91"
|
|
1542
1545
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1543
|
-
checksum = "
|
|
1546
|
+
checksum = "b683b2b825c8eef438b77c36a06dc262294da3d5a5813fac20da149241dcd44d"
|
|
1544
1547
|
dependencies = [
|
|
1545
1548
|
"proc-macro2",
|
|
1546
1549
|
"quote",
|
|
@@ -1593,7 +1596,7 @@ dependencies = [
|
|
|
1593
1596
|
"async-trait",
|
|
1594
1597
|
"base64",
|
|
1595
1598
|
"crossbeam",
|
|
1596
|
-
"dashmap 5.
|
|
1599
|
+
"dashmap 5.2.0",
|
|
1597
1600
|
"derive_builder",
|
|
1598
1601
|
"derive_more",
|
|
1599
1602
|
"enum_dispatch",
|
|
@@ -1625,7 +1628,7 @@ dependencies = [
|
|
|
1625
1628
|
"thiserror",
|
|
1626
1629
|
"tokio",
|
|
1627
1630
|
"tokio-stream",
|
|
1628
|
-
"tokio-util 0.7.
|
|
1631
|
+
"tokio-util 0.7.1",
|
|
1629
1632
|
"tonic",
|
|
1630
1633
|
"tonic-build",
|
|
1631
1634
|
"tracing",
|
|
@@ -1738,9 +1741,9 @@ checksum = "cda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5c"
|
|
|
1738
1741
|
|
|
1739
1742
|
[[package]]
|
|
1740
1743
|
name = "tokio"
|
|
1741
|
-
version = "1.
|
|
1744
|
+
version = "1.17.0"
|
|
1742
1745
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1743
|
-
checksum = "
|
|
1746
|
+
checksum = "2af73ac49756f3f7c01172e34a23e5d0216f6c32333757c2c61feb2bbff5a5ee"
|
|
1744
1747
|
dependencies = [
|
|
1745
1748
|
"bytes",
|
|
1746
1749
|
"libc",
|
|
@@ -1748,9 +1751,10 @@ dependencies = [
|
|
|
1748
1751
|
"mio",
|
|
1749
1752
|
"num_cpus",
|
|
1750
1753
|
"once_cell",
|
|
1751
|
-
"parking_lot 0.
|
|
1754
|
+
"parking_lot 0.12.0",
|
|
1752
1755
|
"pin-project-lite",
|
|
1753
1756
|
"signal-hook-registry",
|
|
1757
|
+
"socket2",
|
|
1754
1758
|
"tokio-macros",
|
|
1755
1759
|
"winapi",
|
|
1756
1760
|
]
|
|
@@ -1814,16 +1818,16 @@ dependencies = [
|
|
|
1814
1818
|
|
|
1815
1819
|
[[package]]
|
|
1816
1820
|
name = "tokio-util"
|
|
1817
|
-
version = "0.7.
|
|
1821
|
+
version = "0.7.1"
|
|
1818
1822
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1819
|
-
checksum = "
|
|
1823
|
+
checksum = "0edfdeb067411dba2044da6d1cb2df793dd35add7888d73c16e3381ded401764"
|
|
1820
1824
|
dependencies = [
|
|
1821
1825
|
"bytes",
|
|
1822
1826
|
"futures-core",
|
|
1823
1827
|
"futures-sink",
|
|
1824
|
-
"log",
|
|
1825
1828
|
"pin-project-lite",
|
|
1826
1829
|
"tokio",
|
|
1830
|
+
"tracing",
|
|
1827
1831
|
]
|
|
1828
1832
|
|
|
1829
1833
|
[[package]]
|
|
@@ -1873,9 +1877,9 @@ dependencies = [
|
|
|
1873
1877
|
|
|
1874
1878
|
[[package]]
|
|
1875
1879
|
name = "tower"
|
|
1876
|
-
version = "0.4.
|
|
1880
|
+
version = "0.4.12"
|
|
1877
1881
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1878
|
-
checksum = "
|
|
1882
|
+
checksum = "9a89fd63ad6adf737582df5db40d286574513c69a11dac5214dc3b5603d6713e"
|
|
1879
1883
|
dependencies = [
|
|
1880
1884
|
"futures-core",
|
|
1881
1885
|
"futures-util",
|
|
@@ -1885,8 +1889,7 @@ dependencies = [
|
|
|
1885
1889
|
"rand",
|
|
1886
1890
|
"slab",
|
|
1887
1891
|
"tokio",
|
|
1888
|
-
"tokio-
|
|
1889
|
-
"tokio-util 0.6.9",
|
|
1892
|
+
"tokio-util 0.7.1",
|
|
1890
1893
|
"tower-layer",
|
|
1891
1894
|
"tower-service",
|
|
1892
1895
|
"tracing",
|
|
@@ -1906,9 +1909,9 @@ checksum = "360dfd1d6d30e05fda32ace2c8c70e9c0a9da713275777f5a4dbb8a1893930c6"
|
|
|
1906
1909
|
|
|
1907
1910
|
[[package]]
|
|
1908
1911
|
name = "tracing"
|
|
1909
|
-
version = "0.1.
|
|
1912
|
+
version = "0.1.34"
|
|
1910
1913
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1911
|
-
checksum = "
|
|
1914
|
+
checksum = "5d0ecdcb44a79f0fe9844f0c4f33a342cbcbb5117de8001e6ba0dc2351327d09"
|
|
1912
1915
|
dependencies = [
|
|
1913
1916
|
"cfg-if",
|
|
1914
1917
|
"log",
|
|
@@ -1919,9 +1922,9 @@ dependencies = [
|
|
|
1919
1922
|
|
|
1920
1923
|
[[package]]
|
|
1921
1924
|
name = "tracing-attributes"
|
|
1922
|
-
version = "0.1.
|
|
1925
|
+
version = "0.1.20"
|
|
1923
1926
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1924
|
-
checksum = "
|
|
1927
|
+
checksum = "2e65ce065b4b5c53e73bb28912318cb8c9e9ad3921f1d669eb0e68b4c8143a2b"
|
|
1925
1928
|
dependencies = [
|
|
1926
1929
|
"proc-macro2",
|
|
1927
1930
|
"quote",
|
|
@@ -1930,9 +1933,9 @@ dependencies = [
|
|
|
1930
1933
|
|
|
1931
1934
|
[[package]]
|
|
1932
1935
|
name = "tracing-core"
|
|
1933
|
-
version = "0.1.
|
|
1936
|
+
version = "0.1.26"
|
|
1934
1937
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1935
|
-
checksum = "
|
|
1938
|
+
checksum = "f54c8ca710e81886d498c2fd3331b56c93aa248d49de2222ad2742247c60072f"
|
|
1936
1939
|
dependencies = [
|
|
1937
1940
|
"lazy_static",
|
|
1938
1941
|
"valuable",
|
|
@@ -1974,14 +1977,14 @@ dependencies = [
|
|
|
1974
1977
|
|
|
1975
1978
|
[[package]]
|
|
1976
1979
|
name = "tracing-subscriber"
|
|
1977
|
-
version = "0.3.
|
|
1980
|
+
version = "0.3.11"
|
|
1978
1981
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1979
|
-
checksum = "
|
|
1982
|
+
checksum = "4bc28f93baff38037f64e6f43d34cfa1605f27a49c34e8a04c5e78b0babf2596"
|
|
1980
1983
|
dependencies = [
|
|
1981
1984
|
"ansi_term",
|
|
1982
1985
|
"lazy_static",
|
|
1983
1986
|
"matchers",
|
|
1984
|
-
"parking_lot 0.
|
|
1987
|
+
"parking_lot 0.12.0",
|
|
1985
1988
|
"regex",
|
|
1986
1989
|
"sharded-slab",
|
|
1987
1990
|
"smallvec",
|
|
@@ -2079,11 +2082,17 @@ version = "0.10.2+wasi-snapshot-preview1"
|
|
|
2079
2082
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2080
2083
|
checksum = "fd6fbd9a79829dd1ad0cc20627bf1ed606756a7f77edff7b66b7064f9cb327c6"
|
|
2081
2084
|
|
|
2085
|
+
[[package]]
|
|
2086
|
+
name = "wasi"
|
|
2087
|
+
version = "0.11.0+wasi-snapshot-preview1"
|
|
2088
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2089
|
+
checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423"
|
|
2090
|
+
|
|
2082
2091
|
[[package]]
|
|
2083
2092
|
name = "wasm-bindgen"
|
|
2084
|
-
version = "0.2.
|
|
2093
|
+
version = "0.2.80"
|
|
2085
2094
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2086
|
-
checksum = "
|
|
2095
|
+
checksum = "27370197c907c55e3f1a9fbe26f44e937fe6451368324e009cba39e139dc08ad"
|
|
2087
2096
|
dependencies = [
|
|
2088
2097
|
"cfg-if",
|
|
2089
2098
|
"wasm-bindgen-macro",
|
|
@@ -2091,9 +2100,9 @@ dependencies = [
|
|
|
2091
2100
|
|
|
2092
2101
|
[[package]]
|
|
2093
2102
|
name = "wasm-bindgen-backend"
|
|
2094
|
-
version = "0.2.
|
|
2103
|
+
version = "0.2.80"
|
|
2095
2104
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2096
|
-
checksum = "
|
|
2105
|
+
checksum = "53e04185bfa3a779273da532f5025e33398409573f348985af9a1cbf3774d3f4"
|
|
2097
2106
|
dependencies = [
|
|
2098
2107
|
"bumpalo",
|
|
2099
2108
|
"lazy_static",
|
|
@@ -2106,9 +2115,9 @@ dependencies = [
|
|
|
2106
2115
|
|
|
2107
2116
|
[[package]]
|
|
2108
2117
|
name = "wasm-bindgen-macro"
|
|
2109
|
-
version = "0.2.
|
|
2118
|
+
version = "0.2.80"
|
|
2110
2119
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2111
|
-
checksum = "
|
|
2120
|
+
checksum = "17cae7ff784d7e83a2fe7611cfe766ecf034111b49deb850a3dc7699c08251f5"
|
|
2112
2121
|
dependencies = [
|
|
2113
2122
|
"quote",
|
|
2114
2123
|
"wasm-bindgen-macro-support",
|
|
@@ -2116,9 +2125,9 @@ dependencies = [
|
|
|
2116
2125
|
|
|
2117
2126
|
[[package]]
|
|
2118
2127
|
name = "wasm-bindgen-macro-support"
|
|
2119
|
-
version = "0.2.
|
|
2128
|
+
version = "0.2.80"
|
|
2120
2129
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2121
|
-
checksum = "
|
|
2130
|
+
checksum = "99ec0dc7a4756fffc231aab1b9f2f578d23cd391390ab27f952ae0c9b3ece20b"
|
|
2122
2131
|
dependencies = [
|
|
2123
2132
|
"proc-macro2",
|
|
2124
2133
|
"quote",
|
|
@@ -2129,15 +2138,15 @@ dependencies = [
|
|
|
2129
2138
|
|
|
2130
2139
|
[[package]]
|
|
2131
2140
|
name = "wasm-bindgen-shared"
|
|
2132
|
-
version = "0.2.
|
|
2141
|
+
version = "0.2.80"
|
|
2133
2142
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2134
|
-
checksum = "
|
|
2143
|
+
checksum = "d554b7f530dee5964d9a9468d95c1f8b8acae4f282807e7d27d4b03099a46744"
|
|
2135
2144
|
|
|
2136
2145
|
[[package]]
|
|
2137
2146
|
name = "web-sys"
|
|
2138
|
-
version = "0.3.
|
|
2147
|
+
version = "0.3.57"
|
|
2139
2148
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2140
|
-
checksum = "
|
|
2149
|
+
checksum = "7b17e741662c70c8bd24ac5c5b18de314a2c26c32bf8346ee1e6f53de919c283"
|
|
2141
2150
|
dependencies = [
|
|
2142
2151
|
"js-sys",
|
|
2143
2152
|
"wasm-bindgen",
|
|
@@ -2155,9 +2164,9 @@ dependencies = [
|
|
|
2155
2164
|
|
|
2156
2165
|
[[package]]
|
|
2157
2166
|
name = "which"
|
|
2158
|
-
version = "4.2.
|
|
2167
|
+
version = "4.2.5"
|
|
2159
2168
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2160
|
-
checksum = "
|
|
2169
|
+
checksum = "5c4fb54e6113b6a8772ee41c3404fb0301ac79604489467e0a9ce1f3e97c24ae"
|
|
2161
2170
|
dependencies = [
|
|
2162
2171
|
"either",
|
|
2163
2172
|
"lazy_static",
|
|
@@ -2188,9 +2197,9 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
|
|
|
2188
2197
|
|
|
2189
2198
|
[[package]]
|
|
2190
2199
|
name = "windows-sys"
|
|
2191
|
-
version = "0.
|
|
2200
|
+
version = "0.34.0"
|
|
2192
2201
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2193
|
-
checksum = "
|
|
2202
|
+
checksum = "5acdd78cb4ba54c0045ac14f62d8f94a03d10047904ae2a40afa1e99d8f70825"
|
|
2194
2203
|
dependencies = [
|
|
2195
2204
|
"windows_aarch64_msvc",
|
|
2196
2205
|
"windows_i686_gnu",
|
|
@@ -2201,30 +2210,30 @@ dependencies = [
|
|
|
2201
2210
|
|
|
2202
2211
|
[[package]]
|
|
2203
2212
|
name = "windows_aarch64_msvc"
|
|
2204
|
-
version = "0.
|
|
2213
|
+
version = "0.34.0"
|
|
2205
2214
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2206
|
-
checksum = "
|
|
2215
|
+
checksum = "17cffbe740121affb56fad0fc0e421804adf0ae00891205213b5cecd30db881d"
|
|
2207
2216
|
|
|
2208
2217
|
[[package]]
|
|
2209
2218
|
name = "windows_i686_gnu"
|
|
2210
|
-
version = "0.
|
|
2219
|
+
version = "0.34.0"
|
|
2211
2220
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2212
|
-
checksum = "
|
|
2221
|
+
checksum = "2564fde759adb79129d9b4f54be42b32c89970c18ebf93124ca8870a498688ed"
|
|
2213
2222
|
|
|
2214
2223
|
[[package]]
|
|
2215
2224
|
name = "windows_i686_msvc"
|
|
2216
|
-
version = "0.
|
|
2225
|
+
version = "0.34.0"
|
|
2217
2226
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2218
|
-
checksum = "
|
|
2227
|
+
checksum = "9cd9d32ba70453522332c14d38814bceeb747d80b3958676007acadd7e166956"
|
|
2219
2228
|
|
|
2220
2229
|
[[package]]
|
|
2221
2230
|
name = "windows_x86_64_gnu"
|
|
2222
|
-
version = "0.
|
|
2231
|
+
version = "0.34.0"
|
|
2223
2232
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2224
|
-
checksum = "
|
|
2233
|
+
checksum = "cfce6deae227ee8d356d19effc141a509cc503dfd1f850622ec4b0f84428e1f4"
|
|
2225
2234
|
|
|
2226
2235
|
[[package]]
|
|
2227
2236
|
name = "windows_x86_64_msvc"
|
|
2228
|
-
version = "0.
|
|
2237
|
+
version = "0.34.0"
|
|
2229
2238
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
2230
|
-
checksum = "
|
|
2239
|
+
checksum = "d19538ccc21819d01deaf88d6a17eae6596a12e9aafdbb97916fb49896d89de9"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@temporalio/core-bridge",
|
|
3
|
-
"version": "0.21.
|
|
3
|
+
"version": "0.21.1",
|
|
4
4
|
"description": "Temporal.io SDK Core<>Node bridge",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"types": "index.d.ts",
|
|
@@ -43,5 +43,5 @@
|
|
|
43
43
|
"publishConfig": {
|
|
44
44
|
"access": "public"
|
|
45
45
|
},
|
|
46
|
-
"gitHead": "
|
|
46
|
+
"gitHead": "c241ab2f8e92966555dbd6d01dc072c8965ee6f4"
|
|
47
47
|
}
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -7,6 +7,7 @@ use tokio::sync::{AcquireError, Semaphore, SemaphorePermit};
|
|
|
7
7
|
/// acquired or restored through the provided methods
|
|
8
8
|
pub(crate) struct MeteredSemaphore {
|
|
9
9
|
pub sem: Semaphore,
|
|
10
|
+
max_permits: usize,
|
|
10
11
|
metrics_ctx: MetricsContext,
|
|
11
12
|
record_fn: fn(&MetricsContext, usize),
|
|
12
13
|
}
|
|
@@ -19,6 +20,7 @@ impl MeteredSemaphore {
|
|
|
19
20
|
) -> Self {
|
|
20
21
|
Self {
|
|
21
22
|
sem: Semaphore::new(inital_permits),
|
|
23
|
+
max_permits: inital_permits,
|
|
22
24
|
metrics_ctx,
|
|
23
25
|
record_fn,
|
|
24
26
|
}
|
|
@@ -30,9 +32,14 @@ impl MeteredSemaphore {
|
|
|
30
32
|
res
|
|
31
33
|
}
|
|
32
34
|
|
|
33
|
-
/// Adds just one permit
|
|
35
|
+
/// Adds just one permit. Will not add if already at the initial/max capacity.
|
|
34
36
|
pub fn add_permit(&self) {
|
|
35
|
-
self.sem.
|
|
36
|
-
|
|
37
|
+
if self.sem.available_permits() < self.max_permits {
|
|
38
|
+
self.sem.add_permits(1);
|
|
39
|
+
(self.record_fn)(&self.metrics_ctx, self.sem.available_permits());
|
|
40
|
+
} else if cfg!(debug_assertions) {
|
|
41
|
+
// Panic only during debug mode if this happens
|
|
42
|
+
panic!("Tried to add permit to a semaphore that already was at capacity!");
|
|
43
|
+
}
|
|
37
44
|
}
|
|
38
45
|
}
|
|
@@ -156,7 +156,12 @@ async fn new_queries(#[case] num_queries: usize) {
|
|
|
156
156
|
let tasks = VecDeque::from(vec![
|
|
157
157
|
hist_to_poll_resp(&t, wfid.to_owned(), 1.into(), TEST_Q.to_string()),
|
|
158
158
|
{
|
|
159
|
-
let mut pr = hist_to_poll_resp(
|
|
159
|
+
let mut pr = hist_to_poll_resp(
|
|
160
|
+
&t,
|
|
161
|
+
wfid.to_owned(),
|
|
162
|
+
ResponseType::OneTask(2),
|
|
163
|
+
TEST_Q.to_string(),
|
|
164
|
+
);
|
|
160
165
|
pr.queries = HashMap::new();
|
|
161
166
|
for i in 1..=num_queries {
|
|
162
167
|
pr.queries.insert(
|
|
@@ -383,20 +388,50 @@ async fn legacy_query_after_complete(#[values(false, true)] full_history: bool)
|
|
|
383
388
|
core.shutdown().await;
|
|
384
389
|
}
|
|
385
390
|
|
|
391
|
+
enum QueryHists {
|
|
392
|
+
Empty,
|
|
393
|
+
Full,
|
|
394
|
+
Partial,
|
|
395
|
+
}
|
|
396
|
+
#[rstest::rstest]
|
|
386
397
|
#[tokio::test]
|
|
387
|
-
async fn query_cache_miss_causes_page_fetch_dont_reply_wft_too_early(
|
|
398
|
+
async fn query_cache_miss_causes_page_fetch_dont_reply_wft_too_early(
|
|
399
|
+
#[values(QueryHists::Empty, QueryHists::Full, QueryHists::Partial)] hist_type: QueryHists,
|
|
400
|
+
) {
|
|
388
401
|
let wfid = "fake_wf_id";
|
|
389
402
|
let query_resp = "response";
|
|
390
403
|
let t = canned_histories::single_timer("1");
|
|
391
404
|
let full_hist = t.get_full_history_info().unwrap();
|
|
392
405
|
let tasks = VecDeque::from(vec![{
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
406
|
+
let mut pr = match hist_type {
|
|
407
|
+
QueryHists::Empty => {
|
|
408
|
+
// Create a no-history poll response. This happens to be easiest to do by just ripping
|
|
409
|
+
// out the history after making a normal one.
|
|
410
|
+
let mut pr = hist_to_poll_resp(
|
|
411
|
+
&t,
|
|
412
|
+
wfid.to_owned(),
|
|
413
|
+
ResponseType::AllHistory,
|
|
414
|
+
TEST_Q.to_string(),
|
|
415
|
+
);
|
|
416
|
+
pr.history = Some(Default::default());
|
|
417
|
+
pr
|
|
418
|
+
}
|
|
419
|
+
QueryHists::Full => hist_to_poll_resp(
|
|
420
|
+
&t,
|
|
421
|
+
wfid.to_owned(),
|
|
422
|
+
ResponseType::AllHistory,
|
|
423
|
+
TEST_Q.to_string(),
|
|
424
|
+
),
|
|
425
|
+
QueryHists::Partial => {
|
|
426
|
+
// Create a partial task
|
|
427
|
+
hist_to_poll_resp(
|
|
428
|
+
&t,
|
|
429
|
+
wfid.to_owned(),
|
|
430
|
+
ResponseType::OneTask(2),
|
|
431
|
+
TEST_Q.to_string(),
|
|
432
|
+
)
|
|
433
|
+
}
|
|
434
|
+
};
|
|
400
435
|
pr.queries = HashMap::new();
|
|
401
436
|
pr.queries.insert(
|
|
402
437
|
"the-query".to_string(),
|
|
@@ -409,14 +444,16 @@ async fn query_cache_miss_causes_page_fetch_dont_reply_wft_too_early() {
|
|
|
409
444
|
pr
|
|
410
445
|
}]);
|
|
411
446
|
let mut mock_client = mock_workflow_client();
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
447
|
+
if !matches!(hist_type, QueryHists::Full) {
|
|
448
|
+
mock_client
|
|
449
|
+
.expect_get_workflow_execution_history()
|
|
450
|
+
.returning(move |_, _, _| {
|
|
451
|
+
Ok(GetWorkflowExecutionHistoryResponse {
|
|
452
|
+
history: Some(full_hist.clone().into()),
|
|
453
|
+
..Default::default()
|
|
454
|
+
})
|
|
455
|
+
});
|
|
456
|
+
}
|
|
420
457
|
mock_client
|
|
421
458
|
.expect_complete_workflow_task()
|
|
422
459
|
.times(1)
|
|
@@ -1260,38 +1260,6 @@ async fn buffered_work_drained_on_shutdown() {
|
|
|
1260
1260
|
});
|
|
1261
1261
|
}
|
|
1262
1262
|
|
|
1263
|
-
#[tokio::test]
|
|
1264
|
-
async fn buffering_tasks_doesnt_count_toward_outstanding_max() {
|
|
1265
|
-
let wfid = "fake_wf_id";
|
|
1266
|
-
let t = canned_histories::single_timer("1");
|
|
1267
|
-
let mock = mock_workflow_client();
|
|
1268
|
-
let mut tasks = VecDeque::new();
|
|
1269
|
-
// A way bigger task list than allowed outstanding tasks
|
|
1270
|
-
tasks.extend(
|
|
1271
|
-
std::iter::repeat(hist_to_poll_resp(
|
|
1272
|
-
&t,
|
|
1273
|
-
wfid.to_owned(),
|
|
1274
|
-
2.into(),
|
|
1275
|
-
TEST_Q.to_string(),
|
|
1276
|
-
))
|
|
1277
|
-
.take(20),
|
|
1278
|
-
);
|
|
1279
|
-
let mut mock = MocksHolder::from_client_with_responses(mock, tasks, []);
|
|
1280
|
-
mock.worker_cfg(|wc| {
|
|
1281
|
-
wc.max_cached_workflows = 10;
|
|
1282
|
-
wc.max_outstanding_workflow_tasks = 5;
|
|
1283
|
-
});
|
|
1284
|
-
let core = mock_worker(mock);
|
|
1285
|
-
// Poll for first WFT
|
|
1286
|
-
core.poll_workflow_activation().await.unwrap();
|
|
1287
|
-
// This will error out when the mock runs out of responses. Otherwise it would hang when we
|
|
1288
|
-
// hit the max
|
|
1289
|
-
assert_matches!(
|
|
1290
|
-
core.poll_workflow_activation().await.unwrap_err(),
|
|
1291
|
-
PollWfError::TonicError(_)
|
|
1292
|
-
);
|
|
1293
|
-
}
|
|
1294
|
-
|
|
1295
1263
|
#[tokio::test]
|
|
1296
1264
|
async fn fail_wft_then_recover() {
|
|
1297
1265
|
let t = canned_histories::long_sequential_timers(1);
|
|
@@ -436,6 +436,7 @@ impl Worker {
|
|
|
436
436
|
Ok(())
|
|
437
437
|
}
|
|
438
438
|
}
|
|
439
|
+
|
|
439
440
|
pub(crate) async fn next_workflow_activation(&self) -> Result<WorkflowActivation, PollWfError> {
|
|
440
441
|
// The poll needs to be in a loop because we can't guarantee tail call optimization in Rust
|
|
441
442
|
// (simply) and we really, really need that for long-poll retries.
|
|
@@ -664,9 +665,9 @@ impl Worker {
|
|
|
664
665
|
Some(a)
|
|
665
666
|
}
|
|
666
667
|
NewWfTaskOutcome::TaskBuffered => {
|
|
667
|
-
//
|
|
668
|
-
//
|
|
669
|
-
|
|
668
|
+
// Though the task is not outstanding in the lang sense, it is outstanding from the
|
|
669
|
+
// server perspective. We used to return a permit here, but that doesn't actually
|
|
670
|
+
// make much sense.
|
|
670
671
|
None
|
|
671
672
|
}
|
|
672
673
|
NewWfTaskOutcome::Autocomplete | NewWfTaskOutcome::LocalActsOutstanding => {
|
|
@@ -252,7 +252,11 @@ impl WorkflowMachines {
|
|
|
252
252
|
|
|
253
253
|
/// Let this workflow know that something we've been waiting locally on has resolved, like a
|
|
254
254
|
/// local activity or side effect
|
|
255
|
-
|
|
255
|
+
///
|
|
256
|
+
/// Returns true if the resolution did anything. EX: If the activity is already canceled and
|
|
257
|
+
/// used the TryCancel or Abandon modes, the resolution is uninteresting.
|
|
258
|
+
pub(crate) fn local_resolution(&mut self, resolution: LocalResolution) -> Result<bool> {
|
|
259
|
+
let mut result_important = true;
|
|
256
260
|
match resolution {
|
|
257
261
|
LocalResolution::LocalActivity(LocalActivityResolution {
|
|
258
262
|
seq,
|
|
@@ -268,6 +272,9 @@ impl WorkflowMachines {
|
|
|
268
272
|
if let Machines::LocalActivityMachine(ref mut lam) = *mach {
|
|
269
273
|
let resps =
|
|
270
274
|
lam.try_resolve(result, runtime, attempt, backoff, original_schedule_time)?;
|
|
275
|
+
if resps.is_empty() {
|
|
276
|
+
result_important = false;
|
|
277
|
+
}
|
|
271
278
|
self.process_machine_responses(mk, resps)?;
|
|
272
279
|
} else {
|
|
273
280
|
return Err(WFMachinesError::Nondeterminism(format!(
|
|
@@ -279,7 +286,7 @@ impl WorkflowMachines {
|
|
|
279
286
|
self.local_activity_data.done_executing(seq);
|
|
280
287
|
}
|
|
281
288
|
}
|
|
282
|
-
Ok(
|
|
289
|
+
Ok(result_important)
|
|
283
290
|
}
|
|
284
291
|
|
|
285
292
|
/// Drain all queued local activities that need executing or cancellation
|
|
@@ -96,7 +96,10 @@ impl WorkflowManager {
|
|
|
96
96
|
|
|
97
97
|
/// Let this workflow know that something we've been waiting locally on has resolved, like a
|
|
98
98
|
/// local activity or side effect
|
|
99
|
-
|
|
99
|
+
///
|
|
100
|
+
/// Returns true if the resolution did anything. EX: If the activity is already canceled and
|
|
101
|
+
/// used the TryCancel or Abandon modes, the resolution is uninteresting.
|
|
102
|
+
pub fn notify_of_local_result(&mut self, resolved: LocalResolution) -> Result<bool> {
|
|
100
103
|
self.machines.local_resolution(resolved)
|
|
101
104
|
}
|
|
102
105
|
|
|
@@ -407,7 +410,7 @@ pub mod managed_wf {
|
|
|
407
410
|
&mut self,
|
|
408
411
|
seq_num: u32,
|
|
409
412
|
result: ActivityExecutionResult,
|
|
410
|
-
) -> Result<
|
|
413
|
+
) -> Result<bool> {
|
|
411
414
|
self.mgr
|
|
412
415
|
.notify_of_local_result(LocalResolution::LocalActivity(LocalActivityResolution {
|
|
413
416
|
seq: seq_num,
|
|
@@ -207,12 +207,18 @@ impl WorkflowTaskManager {
|
|
|
207
207
|
if let Some(reason) = pending_info.needs_eviction {
|
|
208
208
|
act.append_evict_job(reason);
|
|
209
209
|
}
|
|
210
|
-
|
|
211
|
-
|
|
210
|
+
// If for whatever reason we triggered a pending activation but there wasn't
|
|
211
|
+
// actually any work to be done, just ignore that.
|
|
212
|
+
if !act.jobs.is_empty() {
|
|
213
|
+
self.insert_outstanding_activation(&act)?;
|
|
214
|
+
self.cache_manager.lock().touch(&act.run_id);
|
|
215
|
+
Ok(Some(act))
|
|
216
|
+
} else {
|
|
217
|
+
Ok(None)
|
|
218
|
+
}
|
|
212
219
|
})
|
|
213
220
|
{
|
|
214
|
-
|
|
215
|
-
Some(act)
|
|
221
|
+
act
|
|
216
222
|
} else {
|
|
217
223
|
self.request_eviction(
|
|
218
224
|
&pending_info.run_id,
|
|
@@ -618,8 +624,11 @@ impl WorkflowTaskManager {
|
|
|
618
624
|
.get(0)
|
|
619
625
|
.map(|ev| ev.event_id > 1)
|
|
620
626
|
.unwrap_or_default();
|
|
627
|
+
let poll_resp_is_incremental =
|
|
628
|
+
poll_resp_is_incremental || poll_wf_resp.history.events.is_empty();
|
|
629
|
+
|
|
630
|
+
let mut did_miss_cache = !poll_resp_is_incremental;
|
|
621
631
|
|
|
622
|
-
let mut did_miss_cache = false;
|
|
623
632
|
let page_token = if !self.workflow_machines.exists(&run_id) && poll_resp_is_incremental {
|
|
624
633
|
debug!(run_id=?run_id, "Workflow task has partial history, but workflow is not in \
|
|
625
634
|
cache. Will fetch history");
|
|
@@ -765,7 +774,8 @@ impl WorkflowTaskManager {
|
|
|
765
774
|
run_id: &str,
|
|
766
775
|
resolved: LocalResolution,
|
|
767
776
|
) -> Result<(), WorkflowUpdateError> {
|
|
768
|
-
self
|
|
777
|
+
let result_was_important = self
|
|
778
|
+
.workflow_machines
|
|
769
779
|
.access_sync(run_id, |wfm: &mut WorkflowManager| {
|
|
770
780
|
wfm.notify_of_local_result(resolved)
|
|
771
781
|
})?
|
|
@@ -774,7 +784,9 @@ impl WorkflowTaskManager {
|
|
|
774
784
|
run_id: run_id.to_string(),
|
|
775
785
|
})?;
|
|
776
786
|
|
|
777
|
-
|
|
787
|
+
if result_was_important {
|
|
788
|
+
self.needs_activation(run_id);
|
|
789
|
+
}
|
|
778
790
|
Ok(())
|
|
779
791
|
}
|
|
780
792
|
|
|
@@ -117,17 +117,13 @@ impl HistoryInfo {
|
|
|
117
117
|
/// Remove events from the beginning of this history such that it looks like what would've been
|
|
118
118
|
/// delivered on a sticky queue where the previously started task was the one before the last
|
|
119
119
|
/// task in this history.
|
|
120
|
-
///
|
|
121
|
-
/// This is not *fully* accurate in that it will include commands that were part of the last
|
|
122
|
-
/// WFT completion, which the server would typically not include, but it's good enough for
|
|
123
|
-
/// testing.
|
|
124
120
|
pub fn make_incremental(&mut self) {
|
|
125
121
|
let last_complete_ix = self
|
|
126
122
|
.events
|
|
127
123
|
.iter()
|
|
128
124
|
.rposition(|he| he.event_type() == EventType::WorkflowTaskCompleted)
|
|
129
125
|
.expect("Must be a WFT completed event in history");
|
|
130
|
-
self.events.drain(0
|
|
126
|
+
self.events.drain(0..last_complete_ix);
|
|
131
127
|
}
|
|
132
128
|
|
|
133
129
|
pub fn events(&self) -> &[HistoryEvent] {
|
|
@@ -223,7 +219,7 @@ mod tests {
|
|
|
223
219
|
fn incremental_works() {
|
|
224
220
|
let t = single_timer("timer1");
|
|
225
221
|
let hi = t.get_one_wft(2).unwrap();
|
|
226
|
-
assert_eq!(hi.events().len(),
|
|
227
|
-
assert_eq!(hi.events()[0].event_id,
|
|
222
|
+
assert_eq!(hi.events().len(), 5);
|
|
223
|
+
assert_eq!(hi.events()[0].event_id, 4);
|
|
228
224
|
}
|
|
229
225
|
}
|