@SuppressWarnings({"unchecked", "SuspiciousMethodCalls"})
    private void processQueue() {
        SoftValue sv;
        while ((sv = (SoftValue) queue.poll()) != null) {
            // we can access private data!
            map.remove(sv.key);
        }
    }
Traverses the ReferenceQueue and removes garbage-collected SoftValue objects from the backing map
by looking them up using the SoftValue.key data member.
lang/src/main/java/org/apache/shiro/lang/util/SoftHashMap.java