@ConditionalOnMissingBean(name = AttributeDefinitionStore.BEAN_NAME)
        @Bean
        @RefreshScope(proxyMode = ScopedProxyMode.DEFAULT)
        public AttributeDefinitionStore attributeDefinitionStore(
            final ConfigurableApplicationContext applicationContext,
            final CasConfigurationProperties casProperties) throws Exception {
            val builders = applicationContext.getBeansOfType(AttributeDefinitionStoreConfigurer.class).values();
            val store = new DefaultAttributeDefinitionStore();
            store.setScope(casProperties.getServer().getScope());
            builders
                .stream()
                .filter(BeanSupplier::isNotProxy)
                .sorted(AnnotationAwareOrderComparator.INSTANCE)
                .map(AttributeDefinitionStoreConfigurer::load)
                .forEach(store::registerAttributeDefinitions);
            val resource = casProperties.getAuthn().getAttributeRepository().getAttributeDefinitionStore().getJson().getLocation();
            store.importStore(resource);
            store.watchStore(resource);
            return store;
        }
This is {@link CasCoreAuthenticationPrincipalConfiguration}.

@author Misagh Moayyed
@since 5.1.0
core/cas-server-core-authentication/src/main/java/org/apereo/cas/config/CasCoreAuthenticationPrincipalConfiguration.java