Search in sources :

Example 1 with ProtocolDefaults

use of org.jboss.as.clustering.jgroups.ProtocolDefaults in project wildfly by wildfly.

the class ProtocolDefaultsServiceConfigurator method build.

@Override
public ServiceBuilder<?> build(ServiceTarget target) {
    ServiceBuilder<?> builder = new AsyncServiceConfigurator(SERVICE_NAME).build(target);
    Consumer<ProtocolDefaults> defaults = builder.provides(SERVICE_NAME);
    Service service = new FunctionalService<>(defaults, Function.identity(), this);
    return builder.setInstance(service).setInitialMode(ServiceController.Mode.ON_DEMAND);
}
Also used : FunctionalService(org.wildfly.clustering.service.FunctionalService) AsyncServiceConfigurator(org.wildfly.clustering.service.AsyncServiceConfigurator) FunctionalService(org.wildfly.clustering.service.FunctionalService) Service(org.jboss.msc.Service) ProtocolDefaults(org.jboss.as.clustering.jgroups.ProtocolDefaults)

Aggregations

ProtocolDefaults (org.jboss.as.clustering.jgroups.ProtocolDefaults)1 Service (org.jboss.msc.Service)1 AsyncServiceConfigurator (org.wildfly.clustering.service.AsyncServiceConfigurator)1 FunctionalService (org.wildfly.clustering.service.FunctionalService)1