Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat!: replace minimatch with fast-glob
`fast-glob` is indeed fast. When running Helia's add-dir benchmark: Before: ``` ┌─────────┬───────────────────────────┬──────────┬──────────┬──────┬──────────┬──────────────────────────────────────────────────┐ │ (index) │ Implementation │ ops/s │ ms/op │ runs │ p99 │ CID │ ├─────────┼───────────────────────────┼──────────┼──────────┼──────┼──────────┼──────────────────────────────────────────────────┤ │ 0 │ 'helia-fs - src' │ '56.95' │ '17.56' │ 5 │ '53.93' │ 'QmY7YuAvtqk9AaMR8mivfyCdSVFT4sJJwLCLYtKYfwAEKf' │ │ 1 │ 'helia-fs - dist' │ '51.74' │ '19.33' │ 5 │ '81.24' │ 'QmdHWaHWXugHHvP2y4SueC1tWUgQBrrzUHUwEMrdNEd7Cn' │ │ 2 │ 'helia-fs - ../gc/src' │ '190.84' │ '5.24' │ 5 │ '21.17' │ 'QmQvJeSxJdCVi8qWwujznXq8Zs2g3gQVNqJUtr9SDUAK9X' │ │ 3 │ 'helia-mem - src' │ '657.37' │ '1.52' │ 5 │ '2.33' │ 'QmY7YuAvtqk9AaMR8mivfyCdSVFT4sJJwLCLYtKYfwAEKf' │ │ 4 │ 'helia-mem - dist' │ '287.28' │ '3.48' │ 5 │ '4.09' │ 'QmdHWaHWXugHHvP2y4SueC1tWUgQBrrzUHUwEMrdNEd7Cn' │ │ 5 │ 'helia-mem - ../gc/src' │ '860.15' │ '1.16' │ 5 │ '1.32' │ 'QmQvJeSxJdCVi8qWwujznXq8Zs2g3gQVNqJUtr9SDUAK9X' │ │ 6 │ 'kubo - src' │ '16.50' │ '60.60' │ 5 │ '123.53' │ 'QmY7YuAvtqk9AaMR8mivfyCdSVFT4sJJwLCLYtKYfwAEKf' │ │ 7 │ 'kubo - dist' │ '7.01' │ '142.75' │ 5 │ '477.01' │ 'QmdHWaHWXugHHvP2y4SueC1tWUgQBrrzUHUwEMrdNEd7Cn' │ │ 8 │ 'kubo - ../gc/src' │ '13.77' │ '72.61' │ 5 │ '143.97' │ 'QmQvJeSxJdCVi8qWwujznXq8Zs2g3gQVNqJUtr9SDUAK9X' │ │ 9 │ 'kubo-direct - src' │ '17.17' │ '58.23' │ 5 │ '120.34' │ 'QmY7YuAvtqk9AaMR8mivfyCdSVFT4sJJwLCLYtKYfwAEKf' │ │ 10 │ 'kubo-direct - dist' │ '9.41' │ '106.29' │ 5 │ '343.66' │ 'QmdHWaHWXugHHvP2y4SueC1tWUgQBrrzUHUwEMrdNEd7Cn' │ │ 11 │ 'kubo-direct - ../gc/src' │ '19.64' │ '50.92' │ 5 │ '108.67' │ 'QmQvJeSxJdCVi8qWwujznXq8Zs2g3gQVNqJUtr9SDUAK9X' │ └─────────┴───────────────────────────┴──────────┴──────────┴──────┴──────────┴──────────────────────────────────────────────────┘ ``` After: ``` ┌─────────┬───────────────────────────┬──────────┬──────────┬──────┬──────────┬──────────────────────────────────────────────────┐ │ (index) │ Implementation │ ops/s │ ms/op │ runs │ p99 │ CID │ ├─────────┼───────────────────────────┼──────────┼──────────┼──────┼──────────┼──────────────────────────────────────────────────┤ │ 0 │ 'helia-fs - src' │ '110.42' │ '9.06' │ 5 │ '35.54' │ 'QmY7YuAvtqk9AaMR8mivfyCdSVFT4sJJwLCLYtKYfwAEKf' │ │ 1 │ 'helia-fs - dist' │ '44.90' │ '22.27' │ 5 │ '96.31' │ 'QmdHWaHWXugHHvP2y4SueC1tWUgQBrrzUHUwEMrdNEd7Cn' │ │ 2 │ 'helia-fs - ../gc/src' │ '121.47' │ '8.23' │ 5 │ '35.53' │ 'QmQvJeSxJdCVi8qWwujznXq8Zs2g3gQVNqJUtr9SDUAK9X' │ │ 3 │ 'helia-mem - src' │ '697.10' │ '1.43' │ 5 │ '1.99' │ 'QmY7YuAvtqk9AaMR8mivfyCdSVFT4sJJwLCLYtKYfwAEKf' │ │ 4 │ 'helia-mem - dist' │ '332.42' │ '3.01' │ 5 │ '3.38' │ 'QmdHWaHWXugHHvP2y4SueC1tWUgQBrrzUHUwEMrdNEd7Cn' │ │ 5 │ 'helia-mem - ../gc/src' │ '852.31' │ '1.17' │ 5 │ '2.06' │ 'QmQvJeSxJdCVi8qWwujznXq8Zs2g3gQVNqJUtr9SDUAK9X' │ │ 6 │ 'kubo - src' │ '15.02' │ '66.60' │ 5 │ '143.21' │ 'QmY7YuAvtqk9AaMR8mivfyCdSVFT4sJJwLCLYtKYfwAEKf' │ │ 7 │ 'kubo - dist' │ '8.02' │ '124.68' │ 5 │ '450.13' │ 'QmdHWaHWXugHHvP2y4SueC1tWUgQBrrzUHUwEMrdNEd7Cn' │ │ 8 │ 'kubo - ../gc/src' │ '16.75' │ '59.71' │ 5 │ '126.64' │ 'QmQvJeSxJdCVi8qWwujznXq8Zs2g3gQVNqJUtr9SDUAK9X' │ │ 9 │ 'kubo-direct - src' │ '18.70' │ '53.49' │ 5 │ '116.70' │ 'QmY7YuAvtqk9AaMR8mivfyCdSVFT4sJJwLCLYtKYfwAEKf' │ │ 10 │ 'kubo-direct - dist' │ '9.92' │ '100.76' │ 5 │ '343.77' │ 'QmdHWaHWXugHHvP2y4SueC1tWUgQBrrzUHUwEMrdNEd7Cn' │ │ 11 │ 'kubo-direct - ../gc/src' │ '18.20' │ '54.95' │ 5 │ '116.82' │ 'QmQvJeSxJdCVi8qWwujznXq8Zs2g3gQVNqJUtr9SDUAK9X' │ └─────────┴───────────────────────────┴──────────┴──────────┴──────┴──────────┴──────────────────────────────────────────────────┘ ```
- Loading branch information