Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,6 @@ public void testMultipleSnapshotKeyReclaim() throws Exception {
// /vol1/bucket2/bucket2snap1 has been cleaned up from cache map
SnapshotCache snapshotCache = om.getOmSnapshotManager().getSnapshotCache();
assertEquals(2, snapshotCache.size());
assertEquals(2, snapshotCache.getPendingEvictionListSize());
}

@SuppressWarnings("checkstyle:MethodLength")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
/**
* Add reference counter to an object instance.
*/
public class ReferenceCounted<T, U extends ReferenceCountedCallback>
public class ReferenceCounted<T, U>
implements AutoCloseable {

/**
Expand Down Expand Up @@ -95,12 +95,6 @@ public long incrementRefCount() {
long newValTotal = refCount.incrementAndGet();
Preconditions.checkState(newValTotal > 0L,
"Total reference count overflown");

if (refCount.get() == 1L) {
// ref count increased to one (from zero), remove from
// pendingEvictionList if added
parentWithCallback.callback(this);
}
}

return refCount.get();
Expand Down Expand Up @@ -131,11 +125,6 @@ public long decrementRefCount() {
long newValTotal = refCount.decrementAndGet();
Preconditions.checkState(newValTotal >= 0L,
"Total reference count underflow");

if (refCount.get() == 0L) {
// ref count decreased to zero, add to pendingEvictionList
parentWithCallback.callback(this);
}
}

return refCount.get();
Expand Down

This file was deleted.

Loading