From b20bd805b72de17be68f2246d13359d59b2c12b1 Mon Sep 17 00:00:00 2001 From: Richard McDaniel <1130888+rmcdaniel@users.noreply.github.com> Date: Sat, 21 Nov 2026 03:53:34 +0000 Subject: [PATCH 1/2] Prepare SDK 4.22.0 for coordinated payload-limit release --- CHANGELOG.md | 2 ++ Cargo.lock | 2 +- Cargo.toml | 4 ++-- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 614e8ac..c040e45 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ ## Unreleased +## 4.22.0 + - A failed cluster-info read no longer stops a running worker. Startup discovery (query-task authority, Nexus cooperation) and the inline-payload policy read before a report retry a connection failure, timeout, 5xx or 429 diff --git a/Cargo.lock b/Cargo.lock index 38d9c9b..e93b6fc 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -288,7 +288,7 @@ dependencies = [ [[package]] name = "durable-workflow" -version = "4.21.0" +version = "4.22.0" dependencies = [ "apache-avro", "base64 0.22.1", diff --git a/Cargo.toml b/Cargo.toml index 5dc9b3a..d517378 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "durable-workflow" -version = "4.21.0" +version = "4.22.0" edition = "2021" description = "Rust client and worker SDK for Durable Workflow Cloud and self-hosted Server" license = "MIT" @@ -14,7 +14,7 @@ categories = ["api-bindings", "asynchronous"] include = ["/src/**", "/schema/**", "/examples/**", "/Cargo.toml", "/README.md", "/CHANGELOG.md", "/LICENSE", "/tests/fixtures/replay-regressions/published-php-complete-explicit-backoff.json", "/tests/fixtures/sdk-metrics-contract.json", "/tests/fixtures/workflow-task-completion-limits-v1-vectors.json", "/tests/fixtures/auth-configuration/static-credentials-v1.json"] [package.metadata.durable-workflow] -product-train = "4.21.0" +product-train = "4.22.0" compatibility-authority = "protocol-manifests" supported-server-versions = "2.0.0" supported-server-release-baselines = { "2" = "2.0.0", "3" = "3.0.2" } From 85f8a0c472c4a1fb03514387f4d6d5f56c5bc811 Mon Sep 17 00:00:00 2001 From: Richard McDaniel <1130888+rmcdaniel@users.noreply.github.com> Date: Sat, 21 Nov 2026 03:57:24 +0000 Subject: [PATCH 2/2] Preserve gzip encoding through the installed acceptance proxy --- scripts/acceptance/installed-native/proxy.py | 11 ++++++++--- scripts/acceptance/installed-native/test_proxy.py | 3 +++ 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/scripts/acceptance/installed-native/proxy.py b/scripts/acceptance/installed-native/proxy.py index 3d531cd..3a4e166 100644 --- a/scripts/acceptance/installed-native/proxy.py +++ b/scripts/acceptance/installed-native/proxy.py @@ -5,13 +5,14 @@ is held for that many seconds before forwarding, unchanged, so a run or execution deadline passes while the worker waits for the receipt. """ -import http.client, http.server, json, pathlib, re, threading, time +import gzip, http.client, http.server, json, pathlib, re, threading, time state = pathlib.Path('/state') lock = threading.Lock() # Response headers the SDK reads from the native Server; anything else is dropped. FORWARDED_HEADERS = { + 'content-encoding': 'Content-Encoding', 'content-type': 'Content-Type', 'retry-after': 'Retry-After', 'x-durable-workflow-control-plane-version': 'X-Durable-Workflow-Control-Plane-Version', @@ -65,20 +66,24 @@ def handle_request(self): headers = {k: v for k, v in self.headers.items() if k.lower() not in ('host', 'connection')} connection.request(self.command, self.path, body=raw, headers=headers) response = connection.getresponse() + response_headers = forwardable_headers(response.getheaders()) body = response.read() if self.path.endswith(('/fail', '/complete')) and '/workflow-tasks/' in self.path: + receipt = body + if response.getheader('Content-Encoding', '').strip().lower() == 'gzip': + receipt = gzip.decompress(body) event = { 'time': time.time(), 'path': self.path, 'status': response.status, 'delay_seconds': delayed, 'request_attempt': request.get('workflow_task_attempt'), 'failure_type': request.get('failure', {}).get('type'), - 'response': {k: v for k, v in json.loads(body).items() if k != 'server_capabilities'}, + 'response': {k: v for k, v in json.loads(receipt).items() if k != 'server_capabilities'}, } with lock: with (state / 'acks.jsonl').open('a') as log: log.write(json.dumps(event) + '\n') self.send_response(response.status) - for key, value in forwardable_headers(response.getheaders()): + for key, value in response_headers: self.send_header(key, value) self.send_header('Content-Length', str(len(body))) self.send_header('Connection', 'close') diff --git a/scripts/acceptance/installed-native/test_proxy.py b/scripts/acceptance/installed-native/test_proxy.py index 25d9b13..e859e60 100644 --- a/scripts/acceptance/installed-native/test_proxy.py +++ b/scripts/acceptance/installed-native/test_proxy.py @@ -11,6 +11,7 @@ class ForwardableHeadersTest(unittest.TestCase): def test_relays_only_the_reviewed_set(self): relayed = forwardable_headers([ ('Content-Type', 'application/json'), + ('Content-Encoding', 'gzip'), ('X-Durable-Workflow-Protocol-Version', '1.20'), ('Retry-After', '1'), ('Connection', 'keep-alive'), @@ -22,6 +23,7 @@ def test_relays_only_the_reviewed_set(self): ]) self.assertEqual(relayed, [ ('Content-Type', 'application/json'), + ('Content-Encoding', 'gzip'), ('X-Durable-Workflow-Protocol-Version', '1.20'), ('Retry-After', '1'), ]) @@ -31,6 +33,7 @@ def test_reviewed_set_is_exact(self): # this set needs review; request-only names such as # x-durable-workflow-payload-completion must not be relayed. self.assertEqual(frozenset(FORWARDED_HEADERS), frozenset(( + 'content-encoding', 'content-type', 'retry-after', 'x-durable-workflow-control-plane-version',