@Override
    public void save(final Supplier<RegisteredService> supplier,
                     final Consumer<RegisteredService> andThenConsume,
                     final long countExclusive) {
        serviceManagers.forEach(servicesManager -> servicesManager.save(() -> {
            val registeredService = supplier.get();
            return findServicesManager(registeredService).isPresent() ? registeredService : null;
        }, andThenConsume, countExclusive));
    }
This is {@link DefaultChainingServicesManager}.

@author Misagh Moayyed
@since 6.2.0
core/cas-server-core-services-registry/src/main/java/org/apereo/cas/services/mgmt/DefaultChainingServicesManager.java