cachetool: Implement batch mode to speed-up cache processing.
Before, Sandwich was modifying local cache directories by issuing cachetool commands sequentially. But it was painfully slow. This CL implement the cachetool's batch mode that process sequence of command received from the stdin and return the commands results in the stdout. This way, Sandwich just have to launch cachetool once in the background and push to its stdin commands to process. On cache directories populated by big webpages such as cnn.com's home page, the Sandwich cache processing for NoState-Prefetch emulation was taking 491s when spawning one cachetool process for each commands versus 3s with this new online mode. BUG=582080 Review-Url: https://codereview.chromium.org/2114933002 Cr-Commit-Position: refs/heads/master@{#405157}
Showing
This diff is collapsed.
Please register or sign in to comment