public static TypeParameterMatcher find(final Object object, final Class<?> parameterizedSuperclass,
                                            final String typeParamName) {

        final Map<Class<?>, Map<String, TypeParameterMatcher>> findCache = TypeParameterMatcher.findCache.get();
        final Class<?> thisClass = object.getClass();

        final Map<String, TypeParameterMatcher> map = findCache.computeIfAbsent(thisClass, k -> Maps.newHashMap());

        TypeParameterMatcher matcher = map.get(typeParamName);
        if (matcher == null) {
            matcher = get(find0(object, parameterizedSuperclass, typeParamName));
            map.put(typeParamName, matcher);
        }

        return matcher;
    }
Most of the code references the pipeline design of
<a href="https://github.com/netty/netty">Netty</a>.
jraft-rheakv/rheakv-core/src/main/java/com/alipay/sofa/jraft/rhea/util/pipeline/TypeParameterMatcher.java