@Override
    protected String toString(final AuditActionContext auditActionContext) {
        val map = new HashMap<String, Object>(auditActionContext.getClientInfo().getHeaders());
        map.putAll(auditActionContext.getClientInfo().getExtraInfo());
        map.putAll(getMappedAuditActionContext(auditActionContext));
        map.put("applicationContext", applicationContext);
        map.put("logger", LOGGER);

        return FunctionUtils.doUnchecked(() -> {
            val scriptFactory = ExecutableCompiledScriptFactory.getExecutableCompiledScriptFactory();
            return scriptFactory.createTemplate(groovyTemplate, map);
        });

    }
{@link org.apereo.inspektr.audit.AuditTrailManager} that dumps auditable information to a configured logger
prepped by a Groovy script and template.

@author Misagh Moayyed
@since 7.0.0
core/cas-server-core-audit-api/src/main/java/org/apereo/inspektr/audit/support/GroovyAuditTrailManager.java