Review Exception throwing and handling throughtput the library, create specific InterProcessDeadLockException for Chronicle Map deadlocks

This commit is contained in:
leventov
2016-11-19 19:14:53 -06:00
parent 5ae69c3035
commit 37d82f290a
37 changed files with 477 additions and 286 deletions
@@ -62,7 +62,7 @@ public abstract class CompactOffHeapLinearHashTable {
public static long capacityFor(long entriesPerSegment) {
if (entriesPerSegment < 0L)
throw new AssertionError("entriesPerSegment should be positive");
throw new AssertionError("entriesPerSegment should be positive: " + entriesPerSegment);
long capacity = Maths.nextPower2(entriesPerSegment, 64L);
if (entriesPerSegment > MAX_UPPER_BOUND_LOAD_FACTOR * capacity)
capacity *= 2;