@Bean
    @RefreshScope(proxyMode = ScopedProxyMode.DEFAULT)
    public SamlRegisteredServiceMetadataResolver amazonS3SamlRegisteredServiceMetadataResolver(
        final ConfigurableApplicationContext applicationContext,
        final CasConfigurationProperties casProperties,
        @Qualifier(OpenSamlConfigBean.DEFAULT_BEAN_NAME)
        final OpenSamlConfigBean openSamlConfigBean,
        @Qualifier("amazonS3Client")
        final S3Client amazonS3Client) {
        return BeanSupplier.of(SamlRegisteredServiceMetadataResolver.class)
            .when(CONDITION.given(applicationContext.getEnvironment()))
            .supply(() -> {
                val idp = casProperties.getAuthn().getSamlIdp();
                return new AmazonS3SamlRegisteredServiceMetadataResolver(idp, openSamlConfigBean, amazonS3Client);
            })
            .otherwiseProxy()
            .get();
    }
This is {@link SamlIdPAmazonS3RegisteredServiceMetadataConfiguration}.

@author Misagh Moayyed
@since 5.3.0
support/cas-server-support-saml-idp-metadata-aws-s3/src/main/java/org/apereo/cas/config/SamlIdPAmazonS3RegisteredServiceMetadataConfiguration.java