Right now there is no way of changing the default cache size in go-git and its size too small (96 MiB). I've been doing tests changing this value and its performance improved a lot.
Repositories: linux (2013), numpy, tensorflow
Number of rows: 395709
Query: SELECT count(*) FROM commits c NATURAL JOIN ref_commits r WHERE r.ref_name = 'HEAD';
Default cache: 1 row in set (54 min 22.17 sec)
Cache size * 8: 1 row in set (20 min 43.69 sec)
Memory consumption is also not too big. gitbase used 1.3 GiB in this query.
We should add an option to go-git Open to select cache size.
Right now there is no way of changing the default cache size in
go-gitand its size too small (96 MiB). I've been doing tests changing this value and its performance improved a lot.Repositories: linux (2013), numpy, tensorflow
Number of rows: 395709
Query:
SELECT count(*) FROM commits c NATURAL JOIN ref_commits r WHERE r.ref_name = 'HEAD';Default cache:
1 row in set (54 min 22.17 sec)Cache size * 8:
1 row in set (20 min 43.69 sec)Memory consumption is also not too big.
gitbaseused 1.3 GiB in this query.We should add an option to go-git Open to select cache size.