Search in sources :

Example 1 with HotRodStoreResourceDefinition

use of org.jboss.as.clustering.infinispan.subsystem.remote.HotRodStoreResourceDefinition in project wildfly by wildfly.

the class CacheResourceDefinition method register.

@SuppressWarnings("deprecation")
@Override
public ManagementResourceRegistration register(ManagementResourceRegistration parent) {
    ManagementResourceRegistration registration = parent.registerSubModel(this);
    ResourceDescriptor descriptor = this.configurator.apply(new ResourceDescriptor(this.getResourceDescriptionResolver())).addAttributes(Attribute.class).addAttributes(ListAttribute.class).addIgnoredAttributes(EnumSet.complementOf(EnumSet.of(DeprecatedAttribute.MODULE))).addAttributeTranslation(DeprecatedAttribute.MODULE, new ListAttributeTranslation(ListAttribute.MODULES)).addCapabilities(Capability.class).addCapabilities(CLUSTERING_CAPABILITIES.values()).addRequiredChildren(ExpirationResourceDefinition.PATH, LockingResourceDefinition.PATH, TransactionResourceDefinition.PATH).addRequiredSingletonChildren(HeapMemoryResourceDefinition.PATH, NoStoreResourceDefinition.PATH);
    new SimpleResourceRegistration(descriptor, this.handler).register(registration);
    if (registration.isRuntimeOnlyRegistrationValid()) {
        for (DeprecatedMetric metric : EnumSet.allOf(DeprecatedMetric.class)) {
            metric.register(registration);
        }
        for (FixedMetric metric : EnumSet.allOf(FixedMetric.class)) {
            metric.register(registration);
        }
    }
    new HeapMemoryResourceDefinition().register(registration);
    new OffHeapMemoryResourceDefinition().register(registration);
    new ExpirationResourceDefinition().register(registration);
    new LockingResourceDefinition().register(registration);
    new TransactionResourceDefinition().register(registration);
    new NoStoreResourceDefinition().register(registration);
    new CustomStoreResourceDefinition().register(registration);
    new FileStoreResourceDefinition().register(registration);
    new BinaryKeyedJDBCStoreResourceDefinition().register(registration);
    new MixedKeyedJDBCStoreResourceDefinition().register(registration);
    new StringKeyedJDBCStoreResourceDefinition().register(registration);
    new RemoteStoreResourceDefinition().register(registration);
    new HotRodStoreResourceDefinition().register(registration);
    return registration;
}
Also used : BinaryRequirementCapability(org.jboss.as.clustering.controller.BinaryRequirementCapability) ListAttributeTranslation(org.jboss.as.clustering.controller.ListAttributeTranslation) ManagementResourceRegistration(org.jboss.as.clustering.controller.ManagementResourceRegistration) SimpleResourceRegistration(org.jboss.as.clustering.controller.SimpleResourceRegistration) HotRodStoreResourceDefinition(org.jboss.as.clustering.infinispan.subsystem.remote.HotRodStoreResourceDefinition) ResourceDescriptor(org.jboss.as.clustering.controller.ResourceDescriptor)

Aggregations

BinaryRequirementCapability (org.jboss.as.clustering.controller.BinaryRequirementCapability)1 ListAttributeTranslation (org.jboss.as.clustering.controller.ListAttributeTranslation)1 ManagementResourceRegistration (org.jboss.as.clustering.controller.ManagementResourceRegistration)1 ResourceDescriptor (org.jboss.as.clustering.controller.ResourceDescriptor)1 SimpleResourceRegistration (org.jboss.as.clustering.controller.SimpleResourceRegistration)1 HotRodStoreResourceDefinition (org.jboss.as.clustering.infinispan.subsystem.remote.HotRodStoreResourceDefinition)1