-
-
Save joseluisq/9c54197a7bb271ee0ea78fcef2b56bc9 to your computer and use it in GitHub Desktop.
tar-fs vs node-tar benchmarks
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var tar = require('tar'); | |
var fstream = require('fstream'); | |
var input = '/Users/maf/Downloads'; | |
var reader = fstream.Reader({type: "Directory", path: input}); | |
var pack = tar.Pack(); | |
reader.pipe(pack).pipe(tar.Extract({path: '/tmp/destination-node-tar'})); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
time node tar-fs.js | |
real 0m34.261s | |
user 0m11.316s | |
sys 0m16.472s | |
time node node-tar.js | |
real 6m6.123s | |
user 3m8.837s | |
sys 2m43.491s |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var tar = require('tar-fs'); | |
var input = '/Users/maf/Downloads'; | |
tar.pack(input).pipe(tar.extract('/tmp/destination-tar-fs')); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment