use of org.wildfly.clustering.service.SupplierDependency in project wildfly by wildfly.
the class RemoteCacheContainerConfigurationServiceConfigurator method build.
@Override
public ServiceBuilder<?> build(ServiceTarget target) {
ServiceBuilder<?> builder = target.addService(this.getServiceName());
Consumer<Configuration> configuration = new CompositeDependency(this.loader, this.modules, this.connectionPool, this.security, this.server).register(builder).provides(this.getServiceName());
for (Dependency dependency : this.threadPools.values()) {
dependency.register(builder);
}
for (List<SupplierDependency<OutboundSocketBinding>> dependencies : this.clusters.values()) {
for (Dependency dependency : dependencies) {
dependency.register(builder);
}
}
Service service = new FunctionalService<>(configuration, Function.identity(), this);
return builder.setInstance(service).setInitialMode(ServiceController.Mode.ON_DEMAND);
}
Aggregations