@Override
    public boolean submit(final RequestContext requestContext) {
        try {
            val jdbc = aupProperties.getJdbc();
            val aupColumnName = getAcceptableUsagePolicyColumnName(jdbc);
            val sql = String.format(jdbc.getSqlUpdate(), jdbc.getTableName(), aupColumnName, jdbc.getPrincipalIdColumn());
            val principal = WebUtils.getAuthentication(requestContext).getPrincipal();
            val principalId = determinePrincipalId(principal);
            LOGGER.debug("Executing update query [{}] for principal [{}]", sql, principalId);
            return transactionTemplate.execute(action -> jdbcTemplate.update(sql, principalId) > 0);
        } catch (final Exception e) {
            LoggingUtils.error(LOGGER, e);
        }
        return false;
    }
This is {@link JdbcAcceptableUsagePolicyRepository}.
Examines the principal attribute collection to determine if
the policy has been accepted, and if not, allows for a configurable
way so that user's choice can later be remembered and saved back into
the jdbc instance.

@author Misagh Moayyed
@since 5.2
support/cas-server-support-aup-jdbc/src/main/java/org/apereo/cas/aup/JdbcAcceptableUsagePolicyRepository.java