private Map<String, List<Object>> fetchAttributeValueFromExternalGroovyScript(final String file,
                                                                                  final RegisteredServiceAttributeReleasePolicyContext context,
                                                                                  final Map<String, List<Object>> attributes) throws Throwable {
        val cacheMgr = ApplicationContextProvider.getScriptResourceCacheManager().orElseThrow();
        val script = cacheMgr.resolveScriptableResource(file, file);
        return script != null
            ? fetchAttributeValueFromScript(script, context, attributes)
            : new HashMap<>();
    }
This is {@link GroovyScriptAttributeReleasePolicy} that attempts to release attributes
based on the execution result of an external groovy script.

@author Misagh Moayyed
@since 5.0.0
core/cas-server-core-authentication-attributes/src/main/java/org/apereo/cas/services/GroovyScriptAttributeReleasePolicy.java