protected Map<String, List<Object>> convertAttributesToPrincipalAttributesAndCache(final Map<String, List<Object>> sourceAttributes,
                                                                                       final RegisteredServiceAttributeReleasePolicyContext context) {
        val finalAttributes = convertPersonAttributesToPrincipalAttributes(sourceAttributes);
        update(context.getPrincipal().getId(), finalAttributes, context);
        LOGGER.trace("Final principal attributes after caching, if any, are [{}]", finalAttributes);
        return finalAttributes;
    }
The merging strategy that deals with existing principal attributes
and those that are retrieved from the source. By default, existing attributes
are ignored and the source is always consulted.
core/cas-server-core-authentication-attributes/src/main/java/org/apereo/cas/authentication/principal/cache/AbstractPrincipalAttributesRepository.java