use of org.jboss.as.clustering.controller.MetricFunction in project wildfly by wildfly.
the class RemoteCacheMetricExecutor method execute.
@Override
public ModelNode execute(OperationContext context, Metric<RemoteCacheClientStatisticsMXBean> metric) throws OperationFailedException {
ServiceName name = InfinispanClientRequirement.REMOTE_CONTAINER.getServiceName(context, UnaryCapabilityNameResolver.PARENT);
FunctionExecutor<RemoteCacheContainer> executor = this.executors.get(name);
return (executor != null) ? executor.execute(new MetricFunction<>(new RemoteCacheClientStatisticsFactory(context.getCurrentAddressValue()), metric)) : null;
}
use of org.jboss.as.clustering.controller.MetricFunction in project wildfly by wildfly.
the class CacheMetricExecutor method execute.
@Override
public ModelNode execute(OperationContext context, Metric<C> metric) throws OperationFailedException {
ServiceName name = InfinispanCacheRequirement.CACHE.getServiceName(context, this.resolver);
FunctionExecutor<Cache<?, ?>> executor = this.executors.get(name);
return (executor != null) ? executor.execute(new MetricFunction<>(this, metric)) : null;
}
use of org.jboss.as.clustering.controller.MetricFunction in project wildfly by wildfly.
the class CacheContainerMetricExecutor method execute.
@Override
public ModelNode execute(OperationContext context, Metric<EmbeddedCacheManager> metric) throws OperationFailedException {
ServiceName name = InfinispanRequirement.CONTAINER.getServiceName(context, UnaryCapabilityNameResolver.DEFAULT);
FunctionExecutor<EmbeddedCacheManager> executor = this.executors.get(name);
return (executor != null) ? executor.execute(new MetricFunction<>(Function.identity(), metric)) : null;
}
use of org.jboss.as.clustering.controller.MetricFunction in project wildfly by wildfly.
the class RemoteCacheContainerMetricExecutor method execute.
@Override
public ModelNode execute(OperationContext context, Metric<RemoteCacheManagerMXBean> metric) throws OperationFailedException {
ServiceName name = InfinispanClientRequirement.REMOTE_CONTAINER.getServiceName(context, UnaryCapabilityNameResolver.DEFAULT);
FunctionExecutor<RemoteCacheContainer> executor = this.executors.get(name);
return (executor != null) ? executor.execute(new MetricFunction<>(Functions.identity(), metric)) : null;
}
use of org.jboss.as.clustering.controller.MetricFunction in project wildfly by wildfly.
the class ChannelMetricExecutor method execute.
@Override
public ModelNode execute(OperationContext context, Metric<JChannel> metric) throws OperationFailedException {
ServiceName name = JGroupsRequirement.CHANNEL.getServiceName(context, UnaryCapabilityNameResolver.DEFAULT);
FunctionExecutor<JChannel> executor = this.executors.get(name);
return (executor != null) ? executor.execute(new MetricFunction<>(Function.identity(), metric)) : null;
}
Aggregations