diff --git a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementExtension.java b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementExtension.java index 7e851824c3c..bbf09e35742 100644 --- a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementExtension.java +++ b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementExtension.java @@ -49,7 +49,7 @@ public static ResourceDescriptionResolver getResourceDescriptionResolver(final S @Override public void initialize(ExtensionContext context) { final SubsystemRegistration subsystem = context.registerSubsystem(SUBSYSTEM_NAME, CURRENT_VERSION); - subsystem.registerXMLElementWriter(new PersistentResourceXMLDescriptionWriter(CoreManagementSubsystemSchema_1_0.ALL.get(context.getStability()))); + subsystem.registerXMLElementWriter(new PersistentResourceXMLDescriptionWriter(CoreManagementSubsystemSchema.CURRENT.get(context.getStability()))); //This subsystem should be runnable on a host subsystem.setHostCapable(); ManagementResourceRegistration registration = subsystem.registerSubsystemModel(new CoreManagementRootResourceDefinition()); @@ -58,6 +58,6 @@ public void initialize(ExtensionContext context) { @Override public void initializeParsers(ExtensionParsingContext context) { - context.setSubsystemXmlMappings(CoreManagementExtension.SUBSYSTEM_NAME, EnumSet.allOf(CoreManagementSubsystemSchema_1_0.class)); + context.setSubsystemXmlMappings(CoreManagementExtension.SUBSYSTEM_NAME, EnumSet.allOf(CoreManagementSubsystemSchema.class)); } } diff --git a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementRootResourceDefinition.java b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementRootResourceDefinition.java index 643e09658b2..b3ca5609223 100644 --- a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementRootResourceDefinition.java +++ b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementRootResourceDefinition.java @@ -6,31 +6,15 @@ package org.wildfly.extension.core.management; -import org.jboss.as.controller.AbstractBoottimeAddStepHandler; -import org.jboss.as.controller.AttributeDefinition; -import org.jboss.as.controller.OperationContext; -import org.jboss.as.controller.OperationFailedException; -import org.jboss.as.controller.PersistentResourceDefinition; -import org.jboss.as.controller.ReloadRequiredRemoveStepHandler; -import org.jboss.as.controller.registry.Resource; -import org.jboss.as.server.AbstractDeploymentChainStep; -import org.jboss.as.server.DeploymentProcessorTarget; -import org.jboss.dmr.ModelNode; -import org.jboss.msc.service.ServiceBuilder; -import org.wildfly.extension.core.management.UnstableApiAnnotationResourceDefinition.UnstableApiAnnotationLevel; -import org.wildfly.extension.core.management.deployment.ReportUnstableApiAnnotationsProcessor; -import org.wildfly.extension.core.management.deployment.ScanUnstableApiAnnotationsProcessor; - import java.util.Arrays; import java.util.Collection; import java.util.Collections; import java.util.List; -import java.util.function.Consumer; -import static org.jboss.as.server.deployment.Phase.PARSE; -import static org.jboss.as.server.deployment.Phase.PARSE_REPORT_EXPERIMENTAL_ANNOTATIONS; -import static org.jboss.as.server.deployment.Phase.PARSE_SCAN_EXPERIMENTAL_ANNOTATIONS; -import static org.wildfly.extension.core.management.CoreManagementExtension.SUBSYSTEM_NAME; +import org.jboss.as.controller.AttributeDefinition; +import org.jboss.as.controller.ModelOnlyAddStepHandler; +import org.jboss.as.controller.PersistentResourceDefinition; +import org.jboss.as.controller.ReloadRequiredRemoveStepHandler; /** * {@link org.jboss.as.controller.ResourceDefinition} for the core-management subsystem root resource. @@ -42,7 +26,7 @@ class CoreManagementRootResourceDefinition extends PersistentResourceDefinition CoreManagementRootResourceDefinition() { super(CoreManagementExtension.SUBSYSTEM_PATH, CoreManagementExtension.getResourceDescriptionResolver(), - new CoreManagementAddHandler(), + ModelOnlyAddStepHandler.INSTANCE, ReloadRequiredRemoveStepHandler.INSTANCE); } @@ -58,36 +42,4 @@ protected List getChildren() { UnstableApiAnnotationResourceDefinition.INSTANCE ); } - - private static class CoreManagementAddHandler extends AbstractBoottimeAddStepHandler { - - @Override - protected void performBoottime(OperationContext context, ModelNode operation, Resource resource) throws OperationFailedException { - - if (context.isNormalServer()) { - context.addStep(new AbstractDeploymentChainStep() { - @Override - protected void execute(DeploymentProcessorTarget processorTarget) { - processorTarget.addDeploymentProcessor(SUBSYSTEM_NAME, PARSE, PARSE_SCAN_EXPERIMENTAL_ANNOTATIONS, - new ScanUnstableApiAnnotationsProcessor(context.getRunningMode(), context.getStability(), UnstableApiAnnotationService.LEVEL_SUPPLIER)); - processorTarget.addDeploymentProcessor(SUBSYSTEM_NAME, PARSE, PARSE_REPORT_EXPERIMENTAL_ANNOTATIONS, - new ReportUnstableApiAnnotationsProcessor(UnstableApiAnnotationService.LEVEL_SUPPLIER)); - } - }, OperationContext.Stage.RUNTIME); - } - - Resource unstableApiResource = resource.getChild(UnstableApiAnnotationResourceDefinition.PATH); - UnstableApiAnnotationLevel level = null; - if (unstableApiResource != null) { - ModelNode model = unstableApiResource.getModel(); - String levelValue = UnstableApiAnnotationResourceDefinition.LEVEL.resolveModelAttribute(context, model).asString(); - level = UnstableApiAnnotationLevel.valueOf(levelValue); - } - - ServiceBuilder sb = context.getCapabilityServiceTarget().addService(); - Consumer serviceConsumer = sb.provides(UnstableApiAnnotationService.SERVICE_NAME); - sb.setInstance(new UnstableApiAnnotationService(serviceConsumer, level)); - sb.install(); - } - } } diff --git a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementSubsystemSchema_1_0.java b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementSubsystemSchema.java similarity index 86% rename from core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementSubsystemSchema_1_0.java rename to core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementSubsystemSchema.java index aad63bd00ce..371c7d30fb0 100644 --- a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementSubsystemSchema_1_0.java +++ b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/CoreManagementSubsystemSchema.java @@ -25,24 +25,24 @@ * * @author Jeff Mesnil (c) 2016 Red Hat inc. */ -public enum CoreManagementSubsystemSchema_1_0 implements PersistentSubsystemSchema { +public enum CoreManagementSubsystemSchema implements PersistentSubsystemSchema { VERSION_1_0(1), VERSION_1_0_PREVIEW(1, Stability.PREVIEW); - static final Map ALL = Feature.map(EnumSet.of(VERSION_1_0, VERSION_1_0_PREVIEW)); + static final Map CURRENT = Feature.map(EnumSet.of(VERSION_1_0, VERSION_1_0_PREVIEW)); - private final VersionedNamespace namespace; + private final VersionedNamespace namespace; - CoreManagementSubsystemSchema_1_0(int major) { + CoreManagementSubsystemSchema(int major) { this.namespace = SubsystemSchema.createLegacySubsystemURN(CoreManagementExtension.SUBSYSTEM_NAME, new IntVersion(major, 0)); } - CoreManagementSubsystemSchema_1_0(int major, Stability stability) { + CoreManagementSubsystemSchema(int major, Stability stability) { this.namespace = SubsystemSchema.createLegacySubsystemURN(CoreManagementExtension.SUBSYSTEM_NAME, stability, new IntVersion(major, 0)); } @Override - public VersionedNamespace getNamespace() { + public VersionedNamespace getNamespace() { return this.namespace; } diff --git a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/UnstableApiAnnotationResourceDefinition.java b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/UnstableApiAnnotationResourceDefinition.java index 66c359c3e60..5eee3df44be 100644 --- a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/UnstableApiAnnotationResourceDefinition.java +++ b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/UnstableApiAnnotationResourceDefinition.java @@ -4,32 +4,41 @@ */ package org.wildfly.extension.core.management; +import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.SERVICE; +import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.UNSTABLE_API_ANNOTATIONS; +import static org.jboss.as.server.deployment.Phase.PARSE; +import static org.jboss.as.server.deployment.Phase.PARSE_REPORT_EXPERIMENTAL_ANNOTATIONS; +import static org.jboss.as.server.deployment.Phase.PARSE_SCAN_EXPERIMENTAL_ANNOTATIONS; +import static org.wildfly.extension.core.management.CoreManagementExtension.SUBSYSTEM_NAME; + +import java.util.Collection; +import java.util.Collections; +import java.util.List; + +import org.jboss.as.controller.AbstractBoottimeAddStepHandler; import org.jboss.as.controller.AttributeDefinition; +import org.jboss.as.controller.OperationContext; +import org.jboss.as.controller.OperationFailedException; import org.jboss.as.controller.PathElement; import org.jboss.as.controller.PersistentResourceDefinition; -import org.jboss.as.controller.ReloadRequiredAddStepHandler; import org.jboss.as.controller.ReloadRequiredRemoveStepHandler; -import org.jboss.as.controller.ReloadRequiredWriteAttributeHandler; import org.jboss.as.controller.ResourceRegistration; import org.jboss.as.controller.SimpleAttributeDefinition; import org.jboss.as.controller.SimpleAttributeDefinitionBuilder; import org.jboss.as.controller.descriptions.ModelDescriptionConstants; import org.jboss.as.controller.operations.validation.EnumValidator; -import org.jboss.as.controller.registry.ManagementResourceRegistration; +import org.jboss.as.controller.registry.Resource; +import org.jboss.as.server.AbstractDeploymentChainStep; +import org.jboss.as.server.DeploymentProcessorTarget; import org.jboss.as.version.Stability; import org.jboss.dmr.ModelNode; import org.jboss.dmr.ModelType; - -import java.util.Collection; -import java.util.Collections; - -import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.SERVICE; -import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.UNSTABLE_API_ANNOTATIONS; +import org.wildfly.extension.core.management.deployment.ReportUnstableApiAnnotationsProcessor; +import org.wildfly.extension.core.management.deployment.ScanUnstableApiAnnotationsProcessor; /** - * Resource to list all configuration changes. + * Resource to configure the unstable api annotation usage reporting. * - * @author Emmanuel Hugonnet (c) 2015 Red Hat, inc. */ public class UnstableApiAnnotationResourceDefinition extends PersistentResourceDefinition { @@ -38,32 +47,54 @@ public class UnstableApiAnnotationResourceDefinition extends PersistentResourceD ModelDescriptionConstants.LEVEL, ModelType.STRING, true) .setValidator(EnumValidator.create(UnstableApiAnnotationLevel.class)) .setDefaultValue(new ModelNode(UnstableApiAnnotationLevel.LOG.name())) + .setRestartAllServices() .build(); public static final PathElement PATH = PathElement.pathElement(SERVICE, UNSTABLE_API_ANNOTATIONS); static final ResourceRegistration RESOURCE_REGISTRATION = ResourceRegistration.of(PATH, STABILITY); static final UnstableApiAnnotationResourceDefinition INSTANCE = new UnstableApiAnnotationResourceDefinition(); + private static final List ATTRIBUTES = Collections.singletonList(LEVEL); + private UnstableApiAnnotationResourceDefinition() { super( new Parameters( RESOURCE_REGISTRATION, CoreManagementExtension.getResourceDescriptionResolver(UNSTABLE_API_ANNOTATIONS)) - .setAddHandler(ReloadRequiredAddStepHandler.INSTANCE) + .setAddHandler(UnstableApiAnnotationResourceAddHandler.INSTANCE) .setRemoveHandler(ReloadRequiredRemoveStepHandler.INSTANCE)); } @Override - public void registerAttributes(ManagementResourceRegistration resourceRegistration) { - super.registerAttributes(resourceRegistration); - resourceRegistration.registerReadWriteAttribute(LEVEL, null, ReloadRequiredWriteAttributeHandler.INSTANCE); + public Collection getAttributes() { + return ATTRIBUTES; } - @Override - public Collection getAttributes() { - return Collections.emptyList(); + private static class UnstableApiAnnotationResourceAddHandler extends AbstractBoottimeAddStepHandler { + + + static final UnstableApiAnnotationResourceAddHandler INSTANCE = new UnstableApiAnnotationResourceAddHandler(); + @Override + public void performBoottime(OperationContext context, ModelNode operation, Resource resource) throws OperationFailedException { + ModelNode model = resource.getModel(); + String levelValue = UnstableApiAnnotationResourceDefinition.LEVEL.resolveModelAttribute(context, model).asString(); + UnstableApiAnnotationLevel level = UnstableApiAnnotationLevel.valueOf(levelValue); + + if (context.isNormalServer()) { + context.addStep(new AbstractDeploymentChainStep() { + @Override + protected void execute(DeploymentProcessorTarget processorTarget) { + processorTarget.addDeploymentProcessor(SUBSYSTEM_NAME, PARSE, PARSE_SCAN_EXPERIMENTAL_ANNOTATIONS, + new ScanUnstableApiAnnotationsProcessor(context.getRunningMode(), context.getStability(), level)); + processorTarget.addDeploymentProcessor(SUBSYSTEM_NAME, PARSE, PARSE_REPORT_EXPERIMENTAL_ANNOTATIONS, + new ReportUnstableApiAnnotationsProcessor(level)); + } + }, OperationContext.Stage.RUNTIME); + } + } } + public enum UnstableApiAnnotationLevel { LOG, ERROR diff --git a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/UnstableApiAnnotationService.java b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/UnstableApiAnnotationService.java deleted file mode 100644 index 3546f12fe6d..00000000000 --- a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/UnstableApiAnnotationService.java +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright The WildFly Authors - * SPDX-License-Identifier: Apache-2.0 - */ - -package org.wildfly.extension.core.management; - -import org.jboss.msc.Service; -import org.jboss.msc.service.ServiceName; -import org.jboss.msc.service.StartContext; -import org.jboss.msc.service.StartException; -import org.jboss.msc.service.StopContext; -import org.wildfly.extension.core.management.UnstableApiAnnotationResourceDefinition.UnstableApiAnnotationLevel; - -import java.util.function.Consumer; -import java.util.function.Supplier; - -public class UnstableApiAnnotationService implements Service { - - public static ServiceName SERVICE_NAME = ServiceName.JBOSS.append("core-management", "unstable-api-annotation", "level"); - private final Consumer serviceConsumer; - private final UnstableApiAnnotationLevel level; - static final UnstableApiAnnotationLevelSupplier LEVEL_SUPPLIER = new UnstableApiAnnotationLevelSupplier(); - - public UnstableApiAnnotationService(Consumer serviceConsumer, UnstableApiAnnotationLevel level) { - this.serviceConsumer = serviceConsumer; - this.level = level; - } - - public UnstableApiAnnotationLevel getLevel() { - return level; - } - - @Override - public void start(StartContext context) throws StartException { - serviceConsumer.accept(this); - LEVEL_SUPPLIER.level = level; - } - - @Override - public void stop(StopContext context) { - serviceConsumer.accept(null); - LEVEL_SUPPLIER.level = level; - } - - private static class UnstableApiAnnotationLevelSupplier implements Supplier { - private volatile UnstableApiAnnotationLevel level; - @Override - public UnstableApiAnnotationLevel get() { - return level; - } - } - - -} diff --git a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/ReportUnstableApiAnnotationsProcessor.java b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/ReportUnstableApiAnnotationsProcessor.java index 77be273fc16..0e9d5e03ccd 100644 --- a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/ReportUnstableApiAnnotationsProcessor.java +++ b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/ReportUnstableApiAnnotationsProcessor.java @@ -5,6 +5,13 @@ package org.wildfly.extension.core.management.deployment; +import static org.wildfly.extension.core.management.logging.CoreManagementLogger.UNSUPPORTED_ANNOTATION_LOGGER; + +import java.util.ArrayList; +import java.util.Comparator; +import java.util.List; +import java.util.Set; + import org.jboss.as.server.deployment.Attachments; import org.jboss.as.server.deployment.DeploymentPhaseContext; import org.jboss.as.server.deployment.DeploymentUnit; @@ -23,20 +30,12 @@ import org.wildfly.unstable.api.annotation.classpath.runtime.bytecode.ExtendsAnnotatedClass; import org.wildfly.unstable.api.annotation.classpath.runtime.bytecode.ImplementsAnnotatedInterface; -import java.util.ArrayList; -import java.util.Comparator; -import java.util.List; -import java.util.Set; -import java.util.function.Supplier; - -import static org.wildfly.extension.core.management.logging.CoreManagementLogger.UNSUPPORTED_ANNOTATION_LOGGER; - public class ReportUnstableApiAnnotationsProcessor implements DeploymentUnitProcessor { - private final Supplier levelSupplier; + private final UnstableApiAnnotationLevel level; - public ReportUnstableApiAnnotationsProcessor(Supplier levelSupplier) { - this.levelSupplier = levelSupplier; + public ReportUnstableApiAnnotationsProcessor(UnstableApiAnnotationLevel level) { + this.level = level; } /** @@ -122,7 +121,6 @@ private void reportAnnotationUsages(DeploymentUnit top, AnnotationUsages annotat } private AnnotationUsageReporter getAnnotationUsageReporter(DeploymentPhaseContext ctx, DeploymentUnit top) throws DeploymentUnitProcessingException { - UnstableApiAnnotationLevel level = levelSupplier.get(); if (level == UnstableApiAnnotationLevel.ERROR) { return new ErrorAnnotationUsageReporter(); } diff --git a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/ScanUnstableApiAnnotationsProcessor.java b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/ScanUnstableApiAnnotationsProcessor.java index a8fe09622a6..48c7e9ed981 100644 --- a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/ScanUnstableApiAnnotationsProcessor.java +++ b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/ScanUnstableApiAnnotationsProcessor.java @@ -5,6 +5,14 @@ package org.wildfly.extension.core.management.deployment; +import java.io.BufferedReader; +import java.io.IOException; +import java.io.InputStream; +import java.io.InputStreamReader; +import java.net.URL; +import java.util.ArrayList; +import java.util.List; + import org.jboss.as.controller.RunningMode; import org.jboss.as.server.deployment.Attachments; import org.jboss.as.server.deployment.DeploymentPhaseContext; @@ -27,15 +35,6 @@ import org.wildfly.unstable.api.annotation.classpath.index.RuntimeIndex; import org.wildfly.unstable.api.annotation.classpath.runtime.bytecode.ClassInfoScanner; -import java.io.BufferedReader; -import java.io.IOException; -import java.io.InputStream; -import java.io.InputStreamReader; -import java.net.URL; -import java.util.ArrayList; -import java.util.List; -import java.util.function.Supplier; - public class ScanUnstableApiAnnotationsProcessor implements DeploymentUnitProcessor { private final RuntimeIndex runtimeIndex; @@ -48,13 +47,13 @@ public class ScanUnstableApiAnnotationsProcessor implements DeploymentUnitProces private static final String BASE_MODULE_NAME = "org.wildfly._internal.unstable-api-annotation-index"; private static final String INDEX_FILE = "index.txt"; private final Stability stability; - private final Supplier levelSupplier; + private final UnstableApiAnnotationResourceDefinition.UnstableApiAnnotationLevel level; private boolean extraTestOutput; - public ScanUnstableApiAnnotationsProcessor(RunningMode runningMode, Stability stability, Supplier levelSupplier) { + public ScanUnstableApiAnnotationsProcessor(RunningMode runningMode, Stability stability, UnstableApiAnnotationResourceDefinition.UnstableApiAnnotationLevel level) { this.stability = stability; - this.levelSupplier = levelSupplier; + this.level = level; extraTestOutput = System.getProperties().containsKey(EXTRA_TEST_OUTPUT_PROPERTY); boolean enableScanning = true; @@ -106,13 +105,10 @@ public ScanUnstableApiAnnotationsProcessor(RunningMode runningMode, Stability st * @param phaseContext the deployment unit context * @throws DeploymentUnitProcessingException */ - public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { + public void deploy(DeploymentPhaseContext phaseContext) { if (runtimeIndex == null) { return; } - if (levelSupplier.get() == null) { - return; - } final DeploymentUnit du = phaseContext.getDeploymentUnit(); DeploymentUnit top = DeploymentUtils.getTopDeploymentUnit(du); diff --git a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/UnstableApiAnnotationAttachments.java b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/UnstableApiAnnotationAttachments.java index e3218dc28ba..fc8130d02ca 100644 --- a/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/UnstableApiAnnotationAttachments.java +++ b/core-management/core-management-subsystem/src/main/java/org/wildfly/extension/core/management/deployment/UnstableApiAnnotationAttachments.java @@ -9,8 +9,8 @@ import org.wildfly.unstable.api.annotation.classpath.runtime.bytecode.ClassInfoScanner; class UnstableApiAnnotationAttachments { - public static final AttachmentKey UNSTABLE_API_ANNOTATION_SCANNER = AttachmentKey.create(ClassInfoScanner.class); + static final AttachmentKey UNSTABLE_API_ANNOTATION_SCANNER = AttachmentKey.create(ClassInfoScanner.class); - public static final AttachmentKey UNSTABLE_API_ANNOTATIONS_SCANNED = AttachmentKey.create(Boolean.class); + static final AttachmentKey UNSTABLE_API_ANNOTATIONS_SCANNED = AttachmentKey.create(Boolean.class); } diff --git a/core-management/core-management-subsystem/src/test/java/org/wildfly/extension/core/management/CoreManagementSubsystem_1_0_TestCase.java b/core-management/core-management-subsystem/src/test/java/org/wildfly/extension/core/management/CoreManagementSubsystemTestCase.java similarity index 63% rename from core-management/core-management-subsystem/src/test/java/org/wildfly/extension/core/management/CoreManagementSubsystem_1_0_TestCase.java rename to core-management/core-management-subsystem/src/test/java/org/wildfly/extension/core/management/CoreManagementSubsystemTestCase.java index 7392d29e230..6b6c5c17034 100644 --- a/core-management/core-management-subsystem/src/test/java/org/wildfly/extension/core/management/CoreManagementSubsystem_1_0_TestCase.java +++ b/core-management/core-management-subsystem/src/test/java/org/wildfly/extension/core/management/CoreManagementSubsystemTestCase.java @@ -16,15 +16,15 @@ * @author Jeff Mesnil (c) 2016 Red Hat Inc. */ @RunWith(Parameterized.class) -public class CoreManagementSubsystem_1_0_TestCase extends AbstractSubsystemSchemaTest { +public class CoreManagementSubsystemTestCase extends AbstractSubsystemSchemaTest { @Parameterized.Parameters(name = "{0}") - public static Iterable getParameters() { - return EnumSet.allOf(CoreManagementSubsystemSchema_1_0.class); + public static Iterable getParameters() { + return EnumSet.allOf(CoreManagementSubsystemSchema.class); } - public CoreManagementSubsystem_1_0_TestCase(CoreManagementSubsystemSchema_1_0 schema) { - super(CoreManagementExtension.SUBSYSTEM_NAME, new CoreManagementExtension(), schema, CoreManagementSubsystemSchema_1_0.ALL.get(schema.getStability())); + public CoreManagementSubsystemTestCase(CoreManagementSubsystemSchema schema) { + super(CoreManagementExtension.SUBSYSTEM_NAME, new CoreManagementExtension(), schema, CoreManagementSubsystemSchema.CURRENT.get(schema.getStability())); } @Override