Commit 1232311
committed
netsync: Separate mix message request.
The current logic for requesting mix messages from peers was added to
the generic request from peer paths because the old async model required
a lot of additional plumbing.
Now that the sync manager has been converted to a synchronous model, no
additional plumbing is needed and therefore it is much simpler and more
efficient to implement the request logic for mix messages independently.
Also, only a single mix message for a missing pair request is ever
needed at a time, so the additional overhead of taking a slice is not
needed.
Consequently, this separates the logic for requesting a mix message from
a peer from the generic request from peer path into its own specialized
method that is much more efficient.
Finally, it also changes the logic for determining if the mix message
should be requested to make use of the same method as other paths that
handle requesting mix messages. In particular, this means it will no
longer attempt to request recently rejected or removed messages.1 parent 429f244 commit 1232311
2 files changed
+33
-30
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2057 | 2057 | | |
2058 | 2058 | | |
2059 | 2059 | | |
2060 | | - | |
2061 | | - | |
2062 | | - | |
2063 | | - | |
| 2060 | + | |
| 2061 | + | |
| 2062 | + | |
2064 | 2063 | | |
2065 | 2064 | | |
2066 | 2065 | | |
2067 | | - | |
| 2066 | + | |
2068 | 2067 | | |
2069 | 2068 | | |
2070 | 2069 | | |
| |||
2168 | 2167 | | |
2169 | 2168 | | |
2170 | 2169 | | |
2171 | | - | |
2172 | | - | |
2173 | | - | |
2174 | | - | |
2175 | | - | |
2176 | | - | |
2177 | | - | |
2178 | | - | |
2179 | | - | |
2180 | | - | |
2181 | | - | |
| 2170 | + | |
| 2171 | + | |
| 2172 | + | |
2182 | 2173 | | |
2183 | | - | |
2184 | | - | |
2185 | | - | |
2186 | | - | |
2187 | | - | |
| 2174 | + | |
| 2175 | + | |
2188 | 2176 | | |
2189 | | - | |
| 2177 | + | |
| 2178 | + | |
| 2179 | + | |
| 2180 | + | |
| 2181 | + | |
| 2182 | + | |
| 2183 | + | |
| 2184 | + | |
2190 | 2185 | | |
2191 | 2186 | | |
2192 | | - | |
2193 | | - | |
| 2187 | + | |
| 2188 | + | |
| 2189 | + | |
| 2190 | + | |
| 2191 | + | |
| 2192 | + | |
| 2193 | + | |
| 2194 | + | |
2194 | 2195 | | |
2195 | 2196 | | |
2196 | | - | |
| 2197 | + | |
| 2198 | + | |
| 2199 | + | |
| 2200 | + | |
2197 | 2201 | | |
2198 | 2202 | | |
2199 | 2203 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1344 | 1344 | | |
1345 | 1345 | | |
1346 | 1346 | | |
1347 | | - | |
| 1347 | + | |
1348 | 1348 | | |
1349 | 1349 | | |
1350 | 1350 | | |
| |||
1430 | 1430 | | |
1431 | 1431 | | |
1432 | 1432 | | |
1433 | | - | |
| 1433 | + | |
1434 | 1434 | | |
1435 | 1435 | | |
1436 | 1436 | | |
| |||
1852 | 1852 | | |
1853 | 1853 | | |
1854 | 1854 | | |
1855 | | - | |
1856 | | - | |
1857 | | - | |
| 1855 | + | |
| 1856 | + | |
1858 | 1857 | | |
1859 | 1858 | | |
1860 | 1859 | | |
| |||
0 commit comments