Support Parallel Upload/Download Operations
dpb587 opened this issue · comments
For metalinks with multiple large files it would be very helpful to be able to upload and download in parallel. Probably add a parallel
option to source
with a default of 3
.
Experimented on wip-parallel
branch, but it's kind of hacky since there should be some refactoring first. A couple other notes on the commit.
Output now looks like:
$ cat tmp/in-ssoca.json | go run ./in /tmp/
ssoca-client-0.7.1-darwin-amd64 10.78 MiB / 10.78 MiB [===========================================] 100.00% 32s
ssoca-client-0.7.1-linux-amd64 10.95 MiB / 10.95 MiB [===========================================] 100.00% 32s
ssoca-server-0.7.1-darwin-amd64 11.52 MiB / 11.52 MiB [===========================================] 100.00% 17s
ssoca-server-0.7.1-linux-amd64 11.68 MiB / 11.68 MiB [===========================================] 100.00% 17s
ssoca-client-0.7.1-linux-amd64: sha-512: OK
ssoca-client-0.7.1-darwin-amd64: sha-512: OK
ssoca-server-0.7.1-darwin-amd64: sha-512: OK
ssoca-server-0.7.1-linux-amd64: sha-512: OK
{"version":{"version":"0.7.1"},"metadata":[{"name":"files","value":"4"},{"name":"bytes","value":"47112362"}]}