Repository navigation
fix: correct --sender flag and filter list in SSH transfers - #2339
Merged
Merged
Conversation
Two bugs prevented SSH transfers from working: 1. The --sender flag was inverted in RemoteInvocationBuilder: it was added for push (local=sender) instead of pull (local=receiver). Upstream options.c:2598: `if (!am_sender) args[ac++] = "--sender"`. 2. run_pull_transfer sent the filter list before the protocol handshake, causing a deadlock. Now both pull and push set client_mode=true so the server flow sends filters at the correct point (after handshake + compat exchange), matching upstream main.c:1258. Removes the now-unused send_filter_list_to_server function and ProtocolVersion/write_filter_list imports.
oferchen
added a commit
that referenced
this pull request
May 1, 2026
Two bugs prevented SSH transfers from working: 1. The --sender flag was inverted in RemoteInvocationBuilder: it was added for push (local=sender) instead of pull (local=receiver). Upstream options.c:2598: `if (!am_sender) args[ac++] = "--sender"`. 2. run_pull_transfer sent the filter list before the protocol handshake, causing a deadlock. Now both pull and push set client_mode=true so the server flow sends filters at the correct point (after handshake + compat exchange), matching upstream main.c:1258. Removes the now-unused send_filter_list_to_server function and ProtocolVersion/write_filter_list imports.
oferchen
added a commit
that referenced
this pull request
May 5, 2026
Two bugs prevented SSH transfers from working: 1. The --sender flag was inverted in RemoteInvocationBuilder: it was added for push (local=sender) instead of pull (local=receiver). Upstream options.c:2598: `if (!am_sender) args[ac++] = "--sender"`. 2. run_pull_transfer sent the filter list before the protocol handshake, causing a deadlock. Now both pull and push set client_mode=true so the server flow sends filters at the correct point (after handshake + compat exchange), matching upstream main.c:1258. Removes the now-unused send_filter_list_to_server function and ProtocolVersion/write_filter_list imports.
4 tasks done
oferchen
added a commit
that referenced
this pull request
May 18, 2026
…#2339) The `SpillGranularity` knob on `SpillPolicy` was a forward-compat stub. This change makes `SpillableReorderBuffer` honour the field at write time and wires it through `ConcurrentDeltaConfig` so callers can actually pick a strategy: - `WholeBatch` (default): one length-prefixed record per spill event holds every non-hot-zone candidate concatenated. The 4-byte header is paid once per event instead of once per item, and reload decodes the whole record and refills the in-memory ring. - `PerItem`: keeps the historical layout of one record per item, so a single reload only has to decode one payload. `spill_index` keeps mapping sequence -> record offset for both flavours. A new `batch_members` map records the encode-order sibling sequences for whole-batch records so partial evictions survive without corrupting decode order; per-item records skip the map entirely. Three new unit tests cover the contract: `granularity_whole_batch_writes_single_chunk` asserts on-disk size equals `header_bytes + payload_bytes` with a single header per event; `granularity_per_item_writes_n_chunks` asserts the per-item layout pays one header per item; `granularity_per_item_round_trip_byte_identical` plus a matching whole-batch test pin payload integrity across both formats. Closes #2339.
oferchen
added a commit
that referenced
this pull request
May 18, 2026
…#2339) The `SpillGranularity` knob on `SpillPolicy` was a forward-compat stub. This change makes `SpillableReorderBuffer` honour the field at write time and wires it through `ConcurrentDeltaConfig` so callers can actually pick a strategy: - `WholeBatch` (default): one length-prefixed record per spill event holds every non-hot-zone candidate concatenated. The 4-byte header is paid once per event instead of once per item, and reload decodes the whole record and refills the in-memory ring. - `PerItem`: keeps the historical layout of one record per item, so a single reload only has to decode one payload. `spill_index` keeps mapping sequence -> record offset for both flavours. A new `batch_members` map records the encode-order sibling sequences for whole-batch records so partial evictions survive without corrupting decode order; per-item records skip the map entirely. Three new unit tests cover the contract: `granularity_whole_batch_writes_single_chunk` asserts on-disk size equals `header_bytes + payload_bytes` with a single header per event; `granularity_per_item_writes_n_chunks` asserts the per-item layout pays one header per item; `granularity_per_item_round_trip_byte_identical` plus a matching whole-batch test pin payload integrity across both formats. Closes #2339.
oferchen
added a commit
that referenced
this pull request
May 18, 2026
…#2339) (#4428) The `SpillGranularity` knob on `SpillPolicy` was a forward-compat stub. This change makes `SpillableReorderBuffer` honour the field at write time and wires it through `ConcurrentDeltaConfig` so callers can actually pick a strategy: - `WholeBatch` (default): one length-prefixed record per spill event holds every non-hot-zone candidate concatenated. The 4-byte header is paid once per event instead of once per item, and reload decodes the whole record and refills the in-memory ring. - `PerItem`: keeps the historical layout of one record per item, so a single reload only has to decode one payload. `spill_index` keeps mapping sequence -> record offset for both flavours. A new `batch_members` map records the encode-order sibling sequences for whole-batch records so partial evictions survive without corrupting decode order; per-item records skip the map entirely. Three new unit tests cover the contract: `granularity_whole_batch_writes_single_chunk` asserts on-disk size equals `header_bytes + payload_bytes` with a single header per event; `granularity_per_item_writes_n_chunks` asserts the per-item layout pays one header per item; `granularity_per_item_round_trip_byte_identical` plus a matching whole-batch test pin payload integrity across both formats. Closes #2339.
oferchen
added a commit
that referenced
this pull request
May 18, 2026
…#2339) (#4428) The `SpillGranularity` knob on `SpillPolicy` was a forward-compat stub. This change makes `SpillableReorderBuffer` honour the field at write time and wires it through `ConcurrentDeltaConfig` so callers can actually pick a strategy: - `WholeBatch` (default): one length-prefixed record per spill event holds every non-hot-zone candidate concatenated. The 4-byte header is paid once per event instead of once per item, and reload decodes the whole record and refills the in-memory ring. - `PerItem`: keeps the historical layout of one record per item, so a single reload only has to decode one payload. `spill_index` keeps mapping sequence -> record offset for both flavours. A new `batch_members` map records the encode-order sibling sequences for whole-batch records so partial evictions survive without corrupting decode order; per-item records skip the map entirely. Three new unit tests cover the contract: `granularity_whole_batch_writes_single_chunk` asserts on-disk size equals `header_bytes + payload_bytes` with a single header per event; `granularity_per_item_writes_n_chunks` asserts the per-item layout pays one header per item; `granularity_per_item_round_trip_byte_identical` plus a matching whole-batch test pin payload integrity across both formats. Closes #2339.
oferchen
added a commit
that referenced
this pull request
May 18, 2026
…#2339) (#4428) The `SpillGranularity` knob on `SpillPolicy` was a forward-compat stub. This change makes `SpillableReorderBuffer` honour the field at write time and wires it through `ConcurrentDeltaConfig` so callers can actually pick a strategy: - `WholeBatch` (default): one length-prefixed record per spill event holds every non-hot-zone candidate concatenated. The 4-byte header is paid once per event instead of once per item, and reload decodes the whole record and refills the in-memory ring. - `PerItem`: keeps the historical layout of one record per item, so a single reload only has to decode one payload. `spill_index` keeps mapping sequence -> record offset for both flavours. A new `batch_members` map records the encode-order sibling sequences for whole-batch records so partial evictions survive without corrupting decode order; per-item records skip the map entirely. Three new unit tests cover the contract: `granularity_whole_batch_writes_single_chunk` asserts on-disk size equals `header_bytes + payload_bytes` with a single header per event; `granularity_per_item_writes_n_chunks` asserts the per-item layout pays one header per item; `granularity_per_item_round_trip_byte_identical` plus a matching whole-batch test pin payload integrity across both formats. Closes #2339.
oferchen
added a commit
that referenced
this pull request
Aug 24, 2026
…#2339) (#4428) The `SpillGranularity` knob on `SpillPolicy` was a forward-compat stub. This change makes `SpillableReorderBuffer` honour the field at write time and wires it through `ConcurrentDeltaConfig` so callers can actually pick a strategy: - `WholeBatch` (default): one length-prefixed record per spill event holds every non-hot-zone candidate concatenated. The 4-byte header is paid once per event instead of once per item, and reload decodes the whole record and refills the in-memory ring. - `PerItem`: keeps the historical layout of one record per item, so a single reload only has to decode one payload. `spill_index` keeps mapping sequence -> record offset for both flavours. A new `batch_members` map records the encode-order sibling sequences for whole-batch records so partial evictions survive without corrupting decode order; per-item records skip the map entirely. Three new unit tests cover the contract: `granularity_whole_batch_writes_single_chunk` asserts on-disk size equals `header_bytes + payload_bytes` with a single header per event; `granularity_per_item_writes_n_chunks` asserts the per-item layout pays one header per item; `granularity_per_item_round_trip_byte_identical` plus a matching whole-batch test pin payload integrity across both formats. Closes #2339.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
--senderflag inRemoteInvocationBuilder— was added for push instead of pull, causing both sides to enter receiver mode and deadlockrun_pull_transfer— was sent before protocol handshakeclient_mode = truefor both push and pull SSH transfers so filters are sent at the correct protocol point (after handshake + compat exchange)send_filter_list_to_serverfunctionRoot cause: Two bugs introduced when SSH support was first implemented. The
--senderflag logic was opposite to upstreamoptions.c:2598(if (!am_sender) args[ac++] = "--sender"), and the filter list was sent before the handshake instead of after.Test plan