Instead of guesstimating that 10000 (or any fixed number) steps
always fit in a buffer, we can just count the bytes as we write.
Depends on D1436
Lint OK |
Unit Tests OK |
Have you tested the performance impact of this change? Previously we would issue 10k at a time, now if the buffer is 65k and if each entry is 100 bytes (40 byte hash + 60 byte path) then we're only doing 650 at a time. You may need to set remotefilelog.cacheprocess= to force it to fallback to normal ssh fetching to execute this code path in bulk.
remotefilelog/fileserverclient.py | ||
---|---|---|
238 | i += 1 |
Path | Packages | |||
---|---|---|---|---|
M | remotefilelog/fileserverclient.py (27 lines) | |||
M | tests/test-check-config-hg.t (1 line) |
Commit | Local | Parents | Author | Summary | Date |
---|---|---|---|---|---|
342fa1588599 | 4106 | d4e186fc0593 | Kostia Balytskyi | remotefilelog: never deadlock on writing to a pipe | Nov 19 2017, 3:57 PM |
undocumented: remotefilelog.backgroundrepack (bool) | undocumented: remotefilelog.backgroundrepack (bool) | ||||
undocumented: remotefilelog.cachegroup (str) | undocumented: remotefilelog.cachegroup (str) | ||||
undocumented: remotefilelog.data.gencountlimit (int) [2] | undocumented: remotefilelog.data.gencountlimit (int) [2] | ||||
undocumented: remotefilelog.debug (bool) | undocumented: remotefilelog.debug (bool) | ||||
undocumented: remotefilelog.excludepattern (list) | undocumented: remotefilelog.excludepattern (list) | ||||
undocumented: remotefilelog.fastdatapack (bool) | undocumented: remotefilelog.fastdatapack (bool) | ||||
undocumented: remotefilelog.fetchpacks (bool) | undocumented: remotefilelog.fetchpacks (bool) | ||||
undocumented: remotefilelog.fetchwarning (str) | undocumented: remotefilelog.fetchwarning (str) | ||||
undocumented: remotefilelog.getfilesstep (int) [10000] | |||||
undocumented: remotefilelog.history.gencountlimit (int) [2] | undocumented: remotefilelog.history.gencountlimit (int) [2] | ||||
undocumented: remotefilelog.includepattern (list) | undocumented: remotefilelog.includepattern (list) | ||||
undocumented: remotefilelog.pullprefetch (str) | undocumented: remotefilelog.pullprefetch (str) | ||||
undocumented: remotefilelog.reponame (str) | undocumented: remotefilelog.reponame (str) | ||||
undocumented: remotefilelog.server (bool) | undocumented: remotefilelog.server (bool) | ||||
undocumented: remotefilelog.servercachepath (str) | undocumented: remotefilelog.servercachepath (str) | ||||
undocumented: remotefilelog.serverexpiration (int) [30] | undocumented: remotefilelog.serverexpiration (int) [30] | ||||
undocumented: remotefilelog.shallowtrees (bool) | undocumented: remotefilelog.shallowtrees (bool) |
Probably remove the "True"