Created
April 2, 2019 14:17
-
-
Save bibarsov/8ebe8842d573afad11c0521afb144a6b to your computer and use it in GitHub Desktop.
This file contains hidden or 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
public static void main(String[] args) { | |
File file = new File("/Users/tbibarsov/Downloads/1_000_000_Contacts.xlsx"); | |
int[] arr = {100, 500, 1_000, 5_000, 10_000, 25_000, 50_000, 100_000, 500_000, 1_000_000, -1}; | |
for (int i : arr) { | |
long s = System.currentTimeMillis(); | |
RowIterator excelRowIterator = getExcelRowIterator( | |
StreamingReader.builder() | |
.sstCacheSize(i) | |
.open(file) | |
); | |
while (excelRowIterator.hasNext()) { | |
excelRowIterator.next(); | |
} | |
excelRowIterator.close(); | |
long l = System.currentTimeMillis() - s; | |
System.out.println("sstCache: " + i + " , took " + (l / 1000L) + " sec"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment