Commit 2b9bf91
committed
feat(distributed): in_process_mode skips coordinator-to-worker gRPC plumbing
Adds `DistributedConfig::in_process_mode` (default false) and the
`with_distributed_in_process_mode` / `set_distributed_in_process_mode`
setters on `DistributedExt`.
When set, `DistributedExec::prepare_plan` still walks every network
boundary and converts `Stage::Local` to `Stage::Remote` with task→URL
routing (so transports that key off `target_task` continue to work
unchanged), but skips the per-worker gRPC plumbing:
- `send_plan_task` (ships the worker subplan over the coordinator
channel),
- `metrics_collection_task` (background coordinator-channel reader for
metrics),
- `work_unit_feed_task` (work-unit-feed RPC).
Intended for embedders that ship the worker plan over a side channel
and provide their own [`WorkerTransport`] (e.g. a shared-memory mesh
inside a single process). The URL recorded on `RemoteStage::workers`
is meaningful to such transports only insofar as it indexes
`target_task`; the transport is free to ignore the URL string.
Default behaviour for users that don't set the flag is unchanged.1 parent b1cff83 commit 2b9bf91
3 files changed
Lines changed: 53 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
505 | 505 | | |
506 | 506 | | |
507 | 507 | | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
508 | 517 | | |
509 | 518 | | |
510 | 519 | | |
| |||
721 | 730 | | |
722 | 731 | | |
723 | 732 | | |
| 733 | + | |
| 734 | + | |
| 735 | + | |
| 736 | + | |
| 737 | + | |
| 738 | + | |
724 | 739 | | |
725 | 740 | | |
726 | 741 | | |
| |||
840 | 855 | | |
841 | 856 | | |
842 | 857 | | |
| 858 | + | |
| 859 | + | |
| 860 | + | |
| 861 | + | |
843 | 862 | | |
844 | 863 | | |
845 | 864 | | |
| |||
944 | 963 | | |
945 | 964 | | |
946 | 965 | | |
| 966 | + | |
| 967 | + | |
| 968 | + | |
| 969 | + | |
| 970 | + | |
947 | 971 | | |
948 | 972 | | |
949 | 973 | | |
| |||
1060 | 1084 | | |
1061 | 1085 | | |
1062 | 1086 | | |
| 1087 | + | |
| 1088 | + | |
| 1089 | + | |
| 1090 | + | |
| 1091 | + | |
1063 | 1092 | | |
1064 | 1093 | | |
1065 | 1094 | | |
| |||
1176 | 1205 | | |
1177 | 1206 | | |
1178 | 1207 | | |
| 1208 | + | |
| 1209 | + | |
| 1210 | + | |
| 1211 | + | |
| 1212 | + | |
1179 | 1213 | | |
1180 | 1214 | | |
1181 | 1215 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
44 | 53 | | |
45 | 54 | | |
46 | 55 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
170 | 170 | | |
171 | 171 | | |
172 | 172 | | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
173 | 176 | | |
174 | 177 | | |
175 | 178 | | |
| |||
236 | 239 | | |
237 | 240 | | |
238 | 241 | | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
239 | 249 | | |
240 | 250 | | |
241 | 251 | | |
| |||
0 commit comments