Commit 40db71c
Improve host_source locking and ring refresh concurrency
Remove ringDescriber mutex around GetHosts I/O; prevHosts/prevPartitioner
were never written. Use read locks for ConnectAddressAndPort and a
read-fast path for HostnameAndPort. Read peer validity under a single
RLock in isValidPeer. Release errorBroadcaster mutex before sending to
listeners.
remove useless lock in isValidPeer
Patch by Dorian Jaminais; reviewed by João Reis and Bohdan Siryk for CASSGO-1211 parent 941f298 commit 40db71c
2 files changed
Lines changed: 19 additions & 16 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
453 | 453 | | |
454 | 454 | | |
455 | 455 | | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
456 | 464 | | |
457 | 465 | | |
458 | 466 | | |
| |||
463 | 471 | | |
464 | 472 | | |
465 | 473 | | |
466 | | - | |
467 | | - | |
| 474 | + | |
| 475 | + | |
468 | 476 | | |
469 | 477 | | |
470 | 478 | | |
| |||
484 | 492 | | |
485 | 493 | | |
486 | 494 | | |
487 | | - | |
488 | | - | |
489 | | - | |
490 | | - | |
| 495 | + | |
491 | 496 | | |
492 | 497 | | |
493 | 498 | | |
| |||
806 | 811 | | |
807 | 812 | | |
808 | 813 | | |
809 | | - | |
| 814 | + | |
810 | 815 | | |
811 | 816 | | |
812 | 817 | | |
| |||
815 | 820 | | |
816 | 821 | | |
817 | 822 | | |
818 | | - | |
819 | | - | |
820 | | - | |
821 | 823 | | |
822 | 824 | | |
823 | | - | |
| 825 | + | |
824 | 826 | | |
825 | 827 | | |
826 | 828 | | |
827 | 829 | | |
828 | | - | |
| 830 | + | |
829 | 831 | | |
830 | 832 | | |
831 | 833 | | |
| |||
1048 | 1050 | | |
1049 | 1051 | | |
1050 | 1052 | | |
1051 | | - | |
1052 | 1053 | | |
1053 | | - | |
1054 | | - | |
1055 | | - | |
| 1054 | + | |
| 1055 | + | |
1056 | 1056 | | |
1057 | 1057 | | |
| 1058 | + | |
| 1059 | + | |
1058 | 1060 | | |
1059 | 1061 | | |
1060 | 1062 | | |
| |||
0 commit comments