mirror of
https://github.com/OpenHFT/Chronicle-Map.git
synced 2021-09-13 01:26:12 +00:00
Generate extra garbage in MemoryResourcesTest to trigger GC
This commit is contained in:
@@ -77,6 +77,7 @@ public class MemoryResourcesTest {
|
||||
// Wait until Cleaner is called and memory is returned to the system
|
||||
while (nativeMemoryUsedBeforeMap != nativeMemoryUsed()) {
|
||||
System.gc();
|
||||
byte[] garbage = new byte[1_000_000];
|
||||
Thread.yield();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user