default String generate(final String principal, final Service service) {
        return generate(principal, service.getId());
    }
Generates a PersistentId based on some algorithm plus the principal.

@param principal the principal to generate the id for.
@param service   the service for which the id may be generated.
@return the generated persistent id.
api/cas-server-core-api-authentication/src/main/java/org/apereo/cas/authentication/principal/PersistentIdGenerator.java