@Bean
        @ConditionalOnMissingBean(name = "dataSourceUma")
        @RefreshScope(proxyMode = ScopedProxyMode.DEFAULT)
        public DataSource dataSourceUma(
            final ConfigurableApplicationContext applicationContext,
            final CasConfigurationProperties casProperties) {
            return BeanSupplier.of(DataSource.class)
                .when(CONDITION.given(applicationContext.getEnvironment()))
                .supply(() -> JpaBeans.newDataSource(casProperties.getAuthn().getOauth().getUma().getResourceSet().getJpa()))
                .otherwiseProxy()
                .get();
        }
This is {@link CasOAuthUmaJpaAutoConfiguration}.

@author Misagh Moayyed
@since 6.0.0
support/cas-server-support-oauth-uma-jpa/src/main/java/org/apereo/cas/config/CasOAuthUmaJpaAutoConfiguration.java