From 6b44f7ea7ff5390b829f114310521e212ed7c0bf Mon Sep 17 00:00:00 2001 From: Brian Stansberry Date: Sun, 22 Sep 2024 22:05:03 -0500 Subject: [PATCH 1/2] [WFLY-19397] Jakarta Data support in WildFly Preview --- boms/preview-ee/pom.xml | 23 +++ .../asciidoc/WildFly_and_WildFly_Preview.adoc | 9 +- .../asciidoc/_galleon/Galleon_layers.adoc | 6 + .../layers/base/org/hibernate/main/module.xml | 2 + jakarta-data/pom.xml | 106 +++++++++++ .../jakarta/data/JakartaDataExtension.java | 179 ++++++++++++++++++ .../data/_private/JakartaDataLogger.java | 18 ++ .../jakarta/data/LocalDescriptions.properties | 8 + .../wildfly-jakarta-data_preview_1_0.xsd | 15 ++ .../data/JakartaDataSubsystemTestCase.java | 50 +++++ .../jakarta/data/jakarta-data-preview-1.0.xml | 6 + pom.xml | 2 + .../wildfly-feature-pack-build.xml | 2 + preview/galleon-local/pom.xml | 9 + .../feature_groups/domain-host-excludes.xml | 30 ++- .../standalone/jakarta-data/layer-spec.xml | 18 ++ .../base/jakarta/data/api/main/module.xml | 15 ++ .../extension/jakarta/data/main/module.xml | 23 +++ .../domain/HostExcludesTestCase.java | 3 +- testsuite/layers-expansion/pom.xml | 35 +++- .../jboss/as/test/shared/LayersTestBase.java | 5 +- 21 files changed, 549 insertions(+), 15 deletions(-) create mode 100644 jakarta-data/pom.xml create mode 100644 jakarta-data/src/main/java/org/wildfly/extension/jakarta/data/JakartaDataExtension.java create mode 100644 jakarta-data/src/main/java/org/wildfly/extension/jakarta/data/_private/JakartaDataLogger.java create mode 100644 jakarta-data/src/main/resources/org/wildfly/extension/jakarta/data/LocalDescriptions.properties create mode 100644 jakarta-data/src/main/resources/schema/wildfly-jakarta-data_preview_1_0.xsd create mode 100644 jakarta-data/src/test/java/org/wildfly/extension/jakarta/data/JakartaDataSubsystemTestCase.java create mode 100644 jakarta-data/src/test/resources/org/wildfly/extension/jakarta/data/jakarta-data-preview-1.0.xml create mode 100644 preview/galleon-local/src/main/resources/layers/standalone/jakarta-data/layer-spec.xml create mode 100644 preview/galleon-local/src/main/resources/modules/system/layers/base/jakarta/data/api/main/module.xml create mode 100644 preview/galleon-local/src/main/resources/modules/system/layers/base/org/wildfly/extension/jakarta/data/main/module.xml diff --git a/boms/preview-ee/pom.xml b/boms/preview-ee/pom.xml index 29c132183091..5378ed2e1b0e 100644 --- a/boms/preview-ee/pom.xml +++ b/boms/preview-ee/pom.xml @@ -109,6 +109,17 @@ + + jakarta.data + jakarta.data-api + ${version.jakarta.data.jakarta-data-api} + + + * + * + + + jakarta.el jakarta.el-api @@ -568,6 +579,18 @@ + + ${ee.maven.groupId} + wildfly-jakarta-data + ${ee.maven.version} + + + * + * + + + + org.wildfly.deployment wildfly-ee-9-deployment-transformer diff --git a/docs/src/main/asciidoc/WildFly_and_WildFly_Preview.adoc b/docs/src/main/asciidoc/WildFly_and_WildFly_Preview.adoc index e6e1691a5aad..110e8325762f 100644 --- a/docs/src/main/asciidoc/WildFly_and_WildFly_Preview.adoc +++ b/docs/src/main/asciidoc/WildFly_and_WildFly_Preview.adoc @@ -71,11 +71,11 @@ compliance of WildFly Preview should check the https://github.com/wildfly/certif [wildfly-preview-ee11] === EE 11 Support in WildFly Preview -The 32 release introduces a significant inflection in how we are using WildFly Preview. Beginning with this release we are starting to use WildFly Preview to provide a look at what we're doing for Jakarta EE 11 support. EE 11 is not yet GA, and standard WildFly won't support EE 11 before the WildFly 34 release, at earliest. But there are milestone, release candidate and final releases of many EE 11 specs and implementations available, so we decided to provide those in WildFly Preview. This means for a number of EE APIs, WildFly Preview no long provides an EE 10 compatible implementation. +The 32 release introduces a significant inflection in how we are using WildFly Preview. Beginning with this release we are starting to use WildFly Preview to provide a look at what we're doing for Jakarta EE 11 support. EE 11 is not yet GA, and standard WildFly won't support EE 11 before the WildFly 36 release, at earliest. But there are milestone, release candidate and final releases of many EE 11 specs and implementations available, so we decided to provide those in WildFly Preview. This means for a number of EE APIs, WildFly Preview no long provides an EE 10 compatible implementation. However, for a number of specifications that are planning changes for EE 11 we are still offering the EE 10 variant. In future releases we'll shift those to the EE 11 variants. -The following table lists the various Jakarta technologies offered by WildFly Preview 32, along with information about which EE platform version the specification relates to. Note that a number of Jakarta specifications are unchanged between EE 10 and EE 11, while other EE technologies that WildFly offers are not part of EE 11. +The following table lists the various Jakarta technologies offered by WildFly Preview, along with information about which EE platform version the specification relates to. Note that a number of Jakarta specifications are unchanged between EE 10 and EE 11, while other EE technologies that WildFly offers are not part of EE 11. Jakarta Data is a new specification added in EE 11. [cols=",,",options="header"] |======================================================================= @@ -97,6 +97,9 @@ The following table lists the various Jakarta technologies offered by WildFly Pr |Jakarta Contexts and Dependency Injection| 4.1.0 |11 +|Jakarta Data +(_xref:Admin_Guide.adoc#Feature_stability_levels[preview stability] only_)| 1.0 |11 + |Jakarta Debugging Support for Other Languages| 2.0 |10 & 11 |Jakarta Dependency Injection| 2.0 |10 & 11 @@ -120,7 +123,7 @@ The following table lists the various Jakarta technologies offered by WildFly Pr |Jakarta Messaging| 3.1 |10 & 11 | Jakarta MVC -(_preview stability only_)| 2.1| N/A xref:note2[^2^] +(_xref:Admin_Guide.adoc#Feature_stability_levels[preview stability] only_)| 2.1| N/A xref:note2[^2^] |Jakarta Pages| 3.1 |10 diff --git a/docs/src/main/asciidoc/_galleon/Galleon_layers.adoc b/docs/src/main/asciidoc/_galleon/Galleon_layers.adoc index 8304f6626f4c..6117868f5536 100644 --- a/docs/src/main/asciidoc/_galleon/Galleon_layers.adoc +++ b/docs/src/main/asciidoc/_galleon/Galleon_layers.adoc @@ -285,6 +285,12 @@ link:#gal.naming[naming] + | link:#gal.base-server[base-server] + +|[[gal.jaxrs-core]]jakarta-data +|Support for Jakarta Data. (xref:Admin_Guide.adoc#Feature_stability_levels[`preview` stability] in xref:WildFly_and_WildFly_Preview.adoc[WildFly Preview] only) The _link:#gal.jpa[jpa]_ dependency can be excluded and _link:#gal.jpa-distributed[jpa-distributed]_ used instead. +| +link:#gal.jpa[jpa] OR + +link:#gal.jpa-distributed[jpa-distributed] + |[[gal.jaxrs-core]]jaxrs-core |Support for Jakarta RESTful Web Services. | diff --git a/ee-feature-pack/galleon-shared/src/main/resources/modules/system/layers/base/org/hibernate/main/module.xml b/ee-feature-pack/galleon-shared/src/main/resources/modules/system/layers/base/org/hibernate/main/module.xml index 01477b748000..23f1b2fcdb55 100644 --- a/ee-feature-pack/galleon-shared/src/main/resources/modules/system/layers/base/org/hibernate/main/module.xml +++ b/ee-feature-pack/galleon-shared/src/main/resources/modules/system/layers/base/org/hibernate/main/module.xml @@ -23,6 +23,8 @@ + + diff --git a/jakarta-data/pom.xml b/jakarta-data/pom.xml new file mode 100644 index 000000000000..31dbd4ba5081 --- /dev/null +++ b/jakarta-data/pom.xml @@ -0,0 +1,106 @@ + + + + + 4.0.0 + + + org.wildfly + wildfly-parent + + 34.0.0.Beta1-SNAPSHOT + + + wildfly-jakarta-data + + WildFly: Jakarta Data Integration + + + + + ${project.groupId} + wildfly-standard-ee-bom + ${ee.maven.version} + pom + import + + + ${project.groupId} + wildfly-standard-test-bom + ${project.version} + pom + import + + + + + + + + org.wildfly.core + wildfly-server + + + org.wildfly.core + wildfly-subsystem + + + + org.jboss.logging + jboss-logging + + + + org.jboss.logging + jboss-logging-annotations + + provided + true + + + + org.jboss.logging + jboss-logging-processor + + provided + true + + + + org.jboss.msc + jboss-msc + + + + org.kohsuke.metainf-services + metainf-services + provided + true + + + + + junit + junit + test + + + + org.wildfly.core + wildfly-subsystem-test + pom + test + + + + diff --git a/jakarta-data/src/main/java/org/wildfly/extension/jakarta/data/JakartaDataExtension.java b/jakarta-data/src/main/java/org/wildfly/extension/jakarta/data/JakartaDataExtension.java new file mode 100644 index 000000000000..838885c31201 --- /dev/null +++ b/jakarta-data/src/main/java/org/wildfly/extension/jakarta/data/JakartaDataExtension.java @@ -0,0 +1,179 @@ +/* + * Copyright The WildFly Authors + * SPDX-License-Identifier: Apache-2.0 + */ + +package org.wildfly.extension.jakarta.data; + +import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.SUBSYSTEM; +import static org.wildfly.extension.jakarta.data._private.JakartaDataLogger.ROOT_LOGGER; + +import org.jboss.as.controller.Extension; +import org.jboss.as.controller.ModelVersion; +import org.jboss.as.controller.PathElement; +import org.jboss.as.controller.PersistentResourceXMLDescription; +import org.jboss.as.controller.PersistentSubsystemSchema; +import org.jboss.as.controller.ResourceDefinition; +import org.jboss.as.controller.ResourceRegistration; +import org.jboss.as.controller.SubsystemModel; +import org.jboss.as.controller.SubsystemRegistration; +import org.jboss.as.controller.SubsystemSchema; +import org.jboss.as.controller.capability.RuntimeCapability; +import org.jboss.as.controller.descriptions.ParentResourceDescriptionResolver; +import org.jboss.as.controller.descriptions.SubsystemResourceDescriptionResolver; +import org.jboss.as.controller.registry.ManagementResourceRegistration; +import org.jboss.as.controller.registry.RuntimePackageDependency; +import org.jboss.as.controller.xml.VersionedNamespace; +import org.jboss.as.server.DeploymentProcessorTarget; +import org.jboss.as.server.deployment.Attachments; +import org.jboss.as.server.deployment.DeploymentPhaseContext; +import org.jboss.as.server.deployment.DeploymentUnit; +import org.jboss.as.server.deployment.DeploymentUnitProcessor; +import org.jboss.as.server.deployment.Phase; +import org.jboss.as.server.deployment.module.ModuleDependency; +import org.jboss.as.server.deployment.module.ModuleSpecification; +import org.jboss.as.version.Stability; +import org.jboss.modules.Module; +import org.jboss.modules.ModuleLoader; +import org.jboss.staxmapper.IntVersion; +import org.kohsuke.MetaInfServices; +import org.wildfly.subsystem.SubsystemConfiguration; +import org.wildfly.subsystem.SubsystemExtension; +import org.wildfly.subsystem.SubsystemPersistence; +import org.wildfly.subsystem.resource.ManagementResourceRegistrar; +import org.wildfly.subsystem.resource.ManagementResourceRegistrationContext; +import org.wildfly.subsystem.resource.ResourceDescriptor; +import org.wildfly.subsystem.resource.SubsystemResourceDefinitionRegistrar; + + +/** + * WildFly extension that provides Jakarta MVC support based on Eclipse Krazo. + * + * @author Brian Stansberry + */ +@MetaInfServices(Extension.class) +public class JakartaDataExtension extends SubsystemExtension { + + /** + * The name of our subsystem within the model. + */ + static final String SUBSYSTEM_NAME = "jakarta-data"; + private static final Stability FEATURE_STABILITY = Stability.PREVIEW; + + static final PathElement SUBSYSTEM_PATH = PathElement.pathElement(SUBSYSTEM, SUBSYSTEM_NAME); + + public JakartaDataExtension() { + super(SubsystemConfiguration.of(SUBSYSTEM_NAME, JakartaDataSubsystemModel.CURRENT, JakartaDataSubsystemRegistrar::new), + SubsystemPersistence.of(JakartaDataSubsystemSchema.CURRENT)); + } + + @Override + public Stability getStability() { + return FEATURE_STABILITY; + } + + /** + * Model for the 'jakarta-data' subsystem. + */ + public enum JakartaDataSubsystemModel implements SubsystemModel { + VERSION_1_0_0(1, 0, 0), + ; + + static final JakartaDataSubsystemModel CURRENT = VERSION_1_0_0; + + private final ModelVersion version; + + JakartaDataSubsystemModel(int major, int minor, int micro) { + this.version = ModelVersion.create(major, minor, micro); + } + + @Override + public ModelVersion getVersion() { + return this.version; + } + } + + /** + * Schema for the 'jakarta-data' subsystem. + */ + public enum JakartaDataSubsystemSchema implements PersistentSubsystemSchema { + + VERSION_1_0_PREVIEW(1, 0, FEATURE_STABILITY), + ; + + static final JakartaDataSubsystemSchema CURRENT = VERSION_1_0_PREVIEW; + + private final VersionedNamespace namespace; + + JakartaDataSubsystemSchema(int major, int minor, Stability stability) { + this.namespace = SubsystemSchema.createSubsystemURN(SUBSYSTEM_NAME, stability, new IntVersion(major, minor)); + } + + @Override + public VersionedNamespace getNamespace() { + return this.namespace; + } + + @Override + public Stability getStability() { + return this.getNamespace().getStability(); + } + + @Override + public PersistentResourceXMLDescription getXMLDescription() { + PersistentResourceXMLDescription.Factory factory = PersistentResourceXMLDescription.factory(this); + return factory.builder(SUBSYSTEM_PATH).build(); + } + } + + private static final class JakartaDataSubsystemRegistrar implements SubsystemResourceDefinitionRegistrar { + + private static final RuntimeCapability JAKARTA_DATA_CAPABILITY = RuntimeCapability.Builder.of("org.wildfly.jakarta.data") + .addRequirements("org.wildfly.jpa") + .build(); + static final ParentResourceDescriptionResolver RESOLVER = new SubsystemResourceDescriptionResolver(SUBSYSTEM_NAME, JakartaDataSubsystemRegistrar.class); + + static final String JAKARTA_DATA_API = "jakarta.data.api"; + + @Override + public ManagementResourceRegistration register(SubsystemRegistration parent, ManagementResourceRegistrationContext managementResourceRegistrationContext) { + ResourceDefinition definition = ResourceDefinition.builder(ResourceRegistration.of(SUBSYSTEM_PATH), RESOLVER).build(); + ManagementResourceRegistration registration = parent.registerSubsystemModel(definition); + ResourceDescriptor descriptor = ResourceDescriptor.builder(RESOLVER) + .addCapability(JAKARTA_DATA_CAPABILITY) + .withDeploymentChainContributor(JakartaDataSubsystemRegistrar::registerDeploymentUnitProcessors) + .build(); + ManagementResourceRegistrar.of(descriptor).register(registration); + registration.registerAdditionalRuntimePackages( + RuntimePackageDependency.required(JAKARTA_DATA_API) + ); + return registration; + } + + private static void registerDeploymentUnitProcessors(DeploymentProcessorTarget processorTarget) { + processorTarget.addDeploymentProcessor(JakartaDataExtension.SUBSYSTEM_NAME, + Phase.DEPENDENCIES, + Phase.DEPENDENCIES_JPA + 1, + new DeploymentUnitProcessor() { + @Override + public void deploy(DeploymentPhaseContext phaseContext) { + + final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); + final ModuleSpecification moduleSpecification = deploymentUnit.getAttachment(Attachments.MODULE_SPECIFICATION); + final ModuleLoader moduleLoader = Module.getBootModuleLoader(); + + // all applications get the jakarta.persistence module added to their deplyoment by default + addDependencies(moduleSpecification, moduleLoader, deploymentUnit, JAKARTA_DATA_API); + } + }); + } + } + + private static void addDependencies(ModuleSpecification moduleSpecification, ModuleLoader moduleLoader, + DeploymentUnit deploymentUnit, String... moduleIdentifiers) { + for ( String moduleIdentifier : moduleIdentifiers) { + moduleSpecification.addSystemDependency(new ModuleDependency(moduleLoader, moduleIdentifier, false, false, true, false)); + ROOT_LOGGER.debugf("added %s dependency to %s", moduleIdentifier, deploymentUnit.getName()); + } + } +} diff --git a/jakarta-data/src/main/java/org/wildfly/extension/jakarta/data/_private/JakartaDataLogger.java b/jakarta-data/src/main/java/org/wildfly/extension/jakarta/data/_private/JakartaDataLogger.java new file mode 100644 index 000000000000..c367ccda9c5d --- /dev/null +++ b/jakarta-data/src/main/java/org/wildfly/extension/jakarta/data/_private/JakartaDataLogger.java @@ -0,0 +1,18 @@ +/* + * Copyright The WildFly Authors + * SPDX-License-Identifier: Apache-2.0 + */ + +package org.wildfly.extension.jakarta.data._private; + +import java.lang.invoke.MethodHandles; + +import org.jboss.logging.BasicLogger; +import org.jboss.logging.Logger; +import org.jboss.logging.annotations.MessageLogger; + +@MessageLogger(projectCode = "WFLYJDATA", length = 4) +public interface JakartaDataLogger extends BasicLogger { + + JakartaDataLogger ROOT_LOGGER = Logger.getMessageLogger(MethodHandles.lookup(), JakartaDataLogger.class, "org.wildfly.extension.jakarta.data"); +} diff --git a/jakarta-data/src/main/resources/org/wildfly/extension/jakarta/data/LocalDescriptions.properties b/jakarta-data/src/main/resources/org/wildfly/extension/jakarta/data/LocalDescriptions.properties new file mode 100644 index 000000000000..9b7cf05a8329 --- /dev/null +++ b/jakarta-data/src/main/resources/org/wildfly/extension/jakarta/data/LocalDescriptions.properties @@ -0,0 +1,8 @@ +# +# Copyright The WildFly Authors +# SPDX-License-Identifier: Apache-2.0 +# + +jakarta-data=The Jakarta Data subsystem. +jakarta-data.add=Add the Jakarta Data subsystem. +jakarta-data.remove=Remove the Jakarta Data subsystem. diff --git a/jakarta-data/src/main/resources/schema/wildfly-jakarta-data_preview_1_0.xsd b/jakarta-data/src/main/resources/schema/wildfly-jakarta-data_preview_1_0.xsd new file mode 100644 index 000000000000..f0d83da7a969 --- /dev/null +++ b/jakarta-data/src/main/resources/schema/wildfly-jakarta-data_preview_1_0.xsd @@ -0,0 +1,15 @@ + + + + + + + + + + \ No newline at end of file diff --git a/jakarta-data/src/test/java/org/wildfly/extension/jakarta/data/JakartaDataSubsystemTestCase.java b/jakarta-data/src/test/java/org/wildfly/extension/jakarta/data/JakartaDataSubsystemTestCase.java new file mode 100644 index 000000000000..7a264f739f81 --- /dev/null +++ b/jakarta-data/src/test/java/org/wildfly/extension/jakarta/data/JakartaDataSubsystemTestCase.java @@ -0,0 +1,50 @@ +/* + * Copyright The WildFly Authors + * SPDX-License-Identifier: Apache-2.0 + */ + +package org.wildfly.extension.jakarta.data; + +import java.util.EnumSet; + +import org.jboss.as.controller.capability.registry.RuntimeCapabilityRegistry; +import org.jboss.as.controller.extension.ExtensionRegistry; +import org.jboss.as.controller.registry.ManagementResourceRegistration; +import org.jboss.as.controller.registry.Resource; +import org.jboss.as.subsystem.test.AbstractSubsystemSchemaTest; +import org.jboss.as.subsystem.test.AdditionalInitialization; +import org.junit.runner.RunWith; +import org.junit.runners.Parameterized; + +/** + * Standard subsystem tests for the jakarta-data subsystem. + */ +@RunWith(value = Parameterized.class) +public class JakartaDataSubsystemTestCase extends AbstractSubsystemSchemaTest { + @Parameterized.Parameters + public static Iterable parameters() { + return EnumSet.allOf(JakartaDataExtension.JakartaDataSubsystemSchema.class); + } + + public JakartaDataSubsystemTestCase(JakartaDataExtension.JakartaDataSubsystemSchema schema) { + super(JakartaDataExtension.SUBSYSTEM_NAME, new JakartaDataExtension(), schema, JakartaDataExtension.JakartaDataSubsystemSchema.CURRENT); + } + + @Override + protected org.jboss.as.subsystem.test.AdditionalInitialization createAdditionalInitialization() { + return new AdditionalInit(getSubsystemSchema()); + } + + private static class AdditionalInit extends AdditionalInitialization.ManagementAdditionalInitialization { + + private AdditionalInit(JakartaDataExtension.JakartaDataSubsystemSchema schema) { + super(schema); + } + + @Override + protected void initializeExtraSubystemsAndModel(ExtensionRegistry extensionRegistry, Resource rootResource, ManagementResourceRegistration rootRegistration, RuntimeCapabilityRegistry capabilityRegistry) { + super.initializeExtraSubystemsAndModel(extensionRegistry, rootResource, rootRegistration, capabilityRegistry); + registerCapabilities(capabilityRegistry, "org.wildfly.jpa"); + } + } +} diff --git a/jakarta-data/src/test/resources/org/wildfly/extension/jakarta/data/jakarta-data-preview-1.0.xml b/jakarta-data/src/test/resources/org/wildfly/extension/jakarta/data/jakarta-data-preview-1.0.xml new file mode 100644 index 000000000000..abef938d07aa --- /dev/null +++ b/jakarta-data/src/test/resources/org/wildfly/extension/jakarta/data/jakarta-data-preview-1.0.xml @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/pom.xml b/pom.xml index 927a71226a07..a44943fca72a 100644 --- a/pom.xml +++ b/pom.xml @@ -70,6 +70,7 @@ galleon-pack health iiop-openjdk + jakarta-data jaxrs jdr jpa @@ -450,6 +451,7 @@ 2.1.3 2.1.1 2.1.1 + 1.0.0 4.0.1 3.0.3 4.0.1 diff --git a/preview/feature-pack/wildfly-feature-pack-build.xml b/preview/feature-pack/wildfly-feature-pack-build.xml index d3dd514882be..7fcbd98c0695 100644 --- a/preview/feature-pack/wildfly-feature-pack-build.xml +++ b/preview/feature-pack/wildfly-feature-pack-build.xml @@ -86,6 +86,7 @@ org.wildfly.extension.elytron org.wildfly.extension.elytron-oidc-client org.wildfly.extension.health + org.wildfly.extension.jakarta.data org.wildfly.extension.io org.wildfly.extension.messaging-activemq org.wildfly.extension.metrics @@ -141,6 +142,7 @@ org.wildfly.extension.discovery org.wildfly.extension.ee-security org.wildfly.extension.elytron + org.wildfly.extension.jakarta.data org.wildfly.extension.io org.wildfly.extension.messaging-activemq org.wildfly.extension.microprofile.config-smallrye diff --git a/preview/galleon-local/pom.xml b/preview/galleon-local/pom.xml index 0b85ab576d5c..dd5f440d9e77 100644 --- a/preview/galleon-local/pom.xml +++ b/preview/galleon-local/pom.xml @@ -30,6 +30,10 @@ + + jakarta.data + jakarta.data-api + jakarta.el jakarta.el-api @@ -49,6 +53,11 @@ hibernate-search-mapper-orm-outbox-polling + + org.wildfly + wildfly-jakarta-data + + org.wildfly.deployment wildfly-ee-9-deployment-transformer diff --git a/preview/galleon-local/src/main/resources/feature_groups/domain-host-excludes.xml b/preview/galleon-local/src/main/resources/feature_groups/domain-host-excludes.xml index a9ca4bca6a09..657460f70b85 100644 --- a/preview/galleon-local/src/main/resources/feature_groups/domain-host-excludes.xml +++ b/preview/galleon-local/src/main/resources/feature_groups/domain-host-excludes.xml @@ -10,54 +10,66 @@ + value="["org.wildfly.extension.clustering.ejb","org.wildfly.extension.elytron-oidc-client","org.wildfly.extension.opentelemetry","org.wildfly.extension.micrometer","org.wildfly.extension.microprofile.lra-participant","org.wildfly.extension.microprofile.lra-coordinator","org.wildfly.extension.microprofile.telemetry","org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.datao"]"/> + value="["org.wildfly.extension.clustering.ejb","org.wildfly.extension.elytron-oidc-client","org.wildfly.extension.opentelemetry","org.wildfly.extension.micrometer","org.wildfly.extension.microprofile.lra-participant","org.wildfly.extension.microprofile.lra-coordinator","org.wildfly.extension.microprofile.telemetry","org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.datao"]"/> + value="["org.wildfly.extension.clustering.ejb","org.wildfly.extension.micrometer","org.wildfly.extension.microprofile.lra-participant","org.wildfly.extension.microprofile.lra-coordinator","org.wildfly.extension.microprofile.telemetry","org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.datao"]"/> + value="["org.wildfly.extension.clustering.ejb","org.wildfly.extension.micrometer","org.wildfly.extension.microprofile.lra-participant","org.wildfly.extension.microprofile.lra-coordinator","org.wildfly.extension.microprofile.telemetry","org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.datao"]"/> + value="["org.wildfly.extension.micrometer","org.wildfly.extension.microprofile.lra-participant","org.wildfly.extension.microprofile.lra-coordinator","org.wildfly.extension.microprofile.telemetry","org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.datao"]"/> + value="["org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.datao"]"/> + value="["org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.datao"]"/> + value="["org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.datao"]"/> + value="["org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.datao"]"/> + + + + + + + + + + diff --git a/preview/galleon-local/src/main/resources/layers/standalone/jakarta-data/layer-spec.xml b/preview/galleon-local/src/main/resources/layers/standalone/jakarta-data/layer-spec.xml new file mode 100644 index 000000000000..4776ac5d9427 --- /dev/null +++ b/preview/galleon-local/src/main/resources/layers/standalone/jakarta-data/layer-spec.xml @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + \ No newline at end of file diff --git a/preview/galleon-local/src/main/resources/modules/system/layers/base/jakarta/data/api/main/module.xml b/preview/galleon-local/src/main/resources/modules/system/layers/base/jakarta/data/api/main/module.xml new file mode 100644 index 000000000000..acc964247e08 --- /dev/null +++ b/preview/galleon-local/src/main/resources/modules/system/layers/base/jakarta/data/api/main/module.xml @@ -0,0 +1,15 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/preview/galleon-local/src/main/resources/modules/system/layers/base/org/wildfly/extension/jakarta/data/main/module.xml b/preview/galleon-local/src/main/resources/modules/system/layers/base/org/wildfly/extension/jakarta/data/main/module.xml new file mode 100644 index 000000000000..2a2c4d4bcac8 --- /dev/null +++ b/preview/galleon-local/src/main/resources/modules/system/layers/base/org/wildfly/extension/jakarta/data/main/module.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testsuite/domain/src/test/java/org/jboss/as/test/integration/domain/HostExcludesTestCase.java b/testsuite/domain/src/test/java/org/jboss/as/test/integration/domain/HostExcludesTestCase.java index cfe210842954..3cb30dddfcd6 100644 --- a/testsuite/domain/src/test/java/org/jboss/as/test/integration/domain/HostExcludesTestCase.java +++ b/testsuite/domain/src/test/java/org/jboss/as/test/integration/domain/HostExcludesTestCase.java @@ -251,13 +251,14 @@ private static List getCurrentRemovedExtensions() { "org.wildfly.extension.microprofile.telemetry" )); - // List of extensions added only by the WildFly Preview + // List of extensions added only by WildFly Preview. // We do not track changes between different versions of WildFly Preview. // From the point of view of this test, all extensions added in WildFly Preview are always extensions // added in the latest release of WildFly Preview. It is out of the scope of Host Exclusion test // to compute on which WildFly Preview was added such a new extension and track the Host Exclusions between // different WildFly Preview releases. private final Set previewExtensions = new HashSet<>(Arrays.asList( + "org.wildfly.extension.jakarta.data" )); ExtensionConf(String name, ExtensionConf parent, boolean supported) { diff --git a/testsuite/layers-expansion/pom.xml b/testsuite/layers-expansion/pom.xml index 9c59507378ad..17f74c4c1894 100644 --- a/testsuite/layers-expansion/pom.xml +++ b/testsuite/layers-expansion/pom.xml @@ -105,7 +105,7 @@ - + preview.profile @@ -192,6 +192,34 @@ + + jakarta-data-provisioning-test + + provision + + ${provisioning.phase.preview.only} + + ${layers.install.dir}/jakarta-data + + + ${testsuite.full.galleon.pack.groupId} + ${testsuite.full.galleon.pack.artifactId} + ${testsuite.full.galleon.pack.version} + false + false + + + + + standalone + standalone.xml + + jakarta-data + + + + + jaxrs-server-observability-provisioning-test @@ -977,6 +1005,7 @@ infinispan io infinispan + jakarta-data jaxrs jaxrs-server jdr @@ -1029,6 +1058,9 @@ microprofile-platform mvc-krazo + + jpa-distributed + @@ -1083,6 +1115,7 @@ iiop-openjdk infinispan io + jakarta-data jaxrs jaxrs-server jdr diff --git a/testsuite/shared/src/main/java/org/jboss/as/test/shared/LayersTestBase.java b/testsuite/shared/src/main/java/org/jboss/as/test/shared/LayersTestBase.java index 571625da589c..c21b06133150 100644 --- a/testsuite/shared/src/main/java/org/jboss/as/test/shared/LayersTestBase.java +++ b/testsuite/shared/src/main/java/org/jboss/as/test/shared/LayersTestBase.java @@ -252,7 +252,10 @@ public abstract class LayersTestBase { "org.wildfly.extension.mvc-krazo", "jakarta.mvc.api", "org.eclipse.krazo.core", - "org.eclipse.krazo.resteasy" + "org.eclipse.krazo.resteasy", + // Extension not included in the default config + "org.wildfly.extension.jakarta.data", + // "jakarta.data.api" this is an optional dep of org.hibernate }; /** From bf7c73ad5f77d951b791437149ccf8c12a8ad14f Mon Sep 17 00:00:00 2001 From: Darran Lofthouse Date: Tue, 24 Sep 2024 11:21:24 +0100 Subject: [PATCH 2/2] [WFLY-19397] Jakarta Data support in WildFly Preview Host excludes updates. --- .../feature_groups/domain-host-excludes.xml | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/preview/galleon-local/src/main/resources/feature_groups/domain-host-excludes.xml b/preview/galleon-local/src/main/resources/feature_groups/domain-host-excludes.xml index 657460f70b85..66c1af0ba48f 100644 --- a/preview/galleon-local/src/main/resources/feature_groups/domain-host-excludes.xml +++ b/preview/galleon-local/src/main/resources/feature_groups/domain-host-excludes.xml @@ -10,66 +10,66 @@ + value="["org.wildfly.extension.clustering.ejb","org.wildfly.extension.elytron-oidc-client","org.wildfly.extension.opentelemetry","org.wildfly.extension.micrometer","org.wildfly.extension.microprofile.lra-participant","org.wildfly.extension.microprofile.lra-coordinator","org.wildfly.extension.microprofile.telemetry","org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.data"]"/> + value="["org.wildfly.extension.clustering.ejb","org.wildfly.extension.elytron-oidc-client","org.wildfly.extension.opentelemetry","org.wildfly.extension.micrometer","org.wildfly.extension.microprofile.lra-participant","org.wildfly.extension.microprofile.lra-coordinator","org.wildfly.extension.microprofile.telemetry","org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.data"]"/> + value="["org.wildfly.extension.clustering.ejb","org.wildfly.extension.micrometer","org.wildfly.extension.microprofile.lra-participant","org.wildfly.extension.microprofile.lra-coordinator","org.wildfly.extension.microprofile.telemetry","org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.data"]"/> + value="["org.wildfly.extension.clustering.ejb","org.wildfly.extension.micrometer","org.wildfly.extension.microprofile.lra-participant","org.wildfly.extension.microprofile.lra-coordinator","org.wildfly.extension.microprofile.telemetry","org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.data"]"/> + value="["org.wildfly.extension.micrometer","org.wildfly.extension.microprofile.lra-participant","org.wildfly.extension.microprofile.lra-coordinator","org.wildfly.extension.microprofile.telemetry","org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.data"]"/> + value="["org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.data"]"/> + value="["org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.data"]"/> + value="["org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.data"]"/> + value="["org.wildfly.extension.mvc-krazo","org.wildfly.extension.jakarta.data"]"/> + value="["org.wildfly.extension.jakarta.data"]"/> + value="["org.wildfly.extension.jakarta.data"]"/>