testScanningForPackfiles
public void testScanningForPackfiles()
throws Exception
Test packfile scanning while a gc is done from the outside (different
process or different Repository instance). This situation occurs e.g. if
a gerrit server is serving fetch requests while native git is doing a
garbage collection. The test shows that when core.trustfolderstat==true
jgit may miss to detect that a new packfile was created. This situation
is persistent until a new full rescan of the pack directory is triggered.
The test works with two Repository instances working on the same disk
location. One (db) for all write operations (creating commits, doing gc)
and another one (receivingDB) which just reads and which in the end shows
the bug
- Throws:
Exception