default RegisteredService findServiceBy(final String id) {
        return getServicesStream()
            .sorted()
            .filter(r -> r.matches(id))
            .findFirst()
            .orElse(null);
    }
Find a service by matching with the service id.

@param id the id to match with.
@return the registered service
api/cas-server-core-api-services/src/main/java/org/apereo/cas/services/ServiceRegistry.java