Commit dcdec22
Fix persistent stream subscriber registration race (#9927)
* Fix persistent stream registration race
Track the earliest stream token observed while subscriber registration is still in progress and use it to initialize the cursor when handshake has no explicit token.
This removes timing dependence from dropped-client producer scenarios without adding sleeps.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Keep earliest pending stream start token
Address PR feedback by updating pending token selection to retain the oldest token observed while registration is incomplete.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent 63c0c38 commit dcdec22
File tree
2 files changed
+14
-4
lines changed- src/Orleans.Streaming/PersistentStreams
2 files changed
+14
-4
lines changedLines changed: 12 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
243 | 243 | | |
244 | 244 | | |
245 | 245 | | |
| 246 | + | |
246 | 247 | | |
247 | 248 | | |
248 | 249 | | |
| |||
268 | 269 | | |
269 | 270 | | |
270 | 271 | | |
271 | | - | |
| 272 | + | |
| 273 | + | |
272 | 274 | | |
273 | 275 | | |
274 | | - | |
| 276 | + | |
275 | 277 | | |
276 | 278 | | |
277 | 279 | | |
| 280 | + | |
278 | 281 | | |
279 | | - | |
| 282 | + | |
280 | 283 | | |
281 | 284 | | |
282 | 285 | | |
| |||
298 | 301 | | |
299 | 302 | | |
300 | 303 | | |
301 | | - | |
| 304 | + | |
| 305 | + | |
302 | 306 | | |
303 | 307 | | |
304 | 308 | | |
| |||
513 | 517 | | |
514 | 518 | | |
515 | 519 | | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
516 | 524 | | |
517 | 525 | | |
518 | 526 | | |
| |||
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| 36 | + | |
| 37 | + | |
36 | 38 | | |
37 | 39 | | |
38 | 40 | | |
| |||
0 commit comments