@Override
    public Set<PersonAttributes> getPeopleWithMultivaluedAttributes(final Map<String, List<Object>> seed,
                                                                    final PersonAttributeDaoFilter filter,
                                                                    final Set<PersonAttributes> resultPeople) {
        var methodInvocation = new PersonAttributeDaoMethodInvocation(seed);
        var cacheKey = cacheKeyGenerator.generateKey(methodInvocation);

        if (cacheKey != null) {
            var cacheResults = userInfoCache.get(cacheKey);
            if (cacheResults != null) {
                if (nullResultsObject.equals(cacheResults)) {
                    cacheResults = null;
                }
                LOGGER.debug("Retrieved query from cache for key=[{}], results=[{}]", cacheKey, cacheResults);
                this.queries++;
                return cacheResults;
            }
        }

        var queryResults = cachedPersonAttributesDao.getPeopleWithMultivaluedAttributes(seed, filter, resultPeople);

        if (cacheKey != null) {
            if (queryResults != null) {
                userInfoCache.put(cacheKey, queryResults);
            } else if (cacheNullResults) {
                userInfoCache.put(cacheKey, nullResultsObject);
            }
            this.queries++;
            this.misses++;
        }

        return queryResults;
    }
A configurable caching implementation of {@link PersonAttributeDao}
which caches results from a wrapped {@link PersonAttributeDao}.

@author dgrimwood@unicon.net
@author Eric Dalquist
@since 7.1.0
support/cas-server-support-person-directory-core/src/main/java/org/apereo/cas/persondir/cache/CachingPersonAttributeDaoImpl.java