Update EE11 dependencies (#5668)

* Update EE11 dependencies

Signed-off-by: jansupol <jan.supol@oracle.com>
diff --git a/NOTICE.md b/NOTICE.md
index 1a42ed5..877100d 100644
--- a/NOTICE.md
+++ b/NOTICE.md
@@ -41,7 +41,7 @@
 * Project: http://aopalliance.sourceforge.net

 * Copyright: Material in the public domain is not protected by copyright

 

-Bean Validation API 3.1.0-M1

+Bean Validation API 3.1.0

 * License: Apache License, 2.0

 * Project: https://projects.eclipse.org/projects/ee4j.bean-validation

 * Copyright: 2009, Red Hat, Inc. and/or its affiliates, and individual contributors

diff --git a/archetypes/jersey-heroku-webapp/src/main/resources/archetype-resources/pom.xml b/archetypes/jersey-heroku-webapp/src/main/resources/archetype-resources/pom.xml
index eca7911..b806939 100644
--- a/archetypes/jersey-heroku-webapp/src/main/resources/archetype-resources/pom.xml
+++ b/archetypes/jersey-heroku-webapp/src/main/resources/archetype-resources/pom.xml
@@ -91,7 +91,7 @@
             <plugin>
                 <groupId>org.eclipse.jetty.ee10</groupId>
                 <artifactId>jetty-ee10-maven-plugin</artifactId>
-                <version>\${jetty.version}</version>
+                <version>\${jetty.plugin.version}</version>
                 <configuration>
                     <contextPath>/</contextPath>
                     <webApp>
@@ -117,7 +117,7 @@
 
     <properties>
         <jersey.version>${project.version}</jersey.version>
-        <jetty.version>12.0.7</jetty.version>
+        <jetty.plugin.version>12.0.8</jetty.plugin.version>
         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
         <surefire.mvn.plugin.version>3.2.5</surefire.mvn.plugin.version>
         <war.mvn.plugin.version>3.4.0</war.mvn.plugin.version>
diff --git a/etc/scripts/apidocs.sh b/etc/scripts/apidocs.sh
index 12b2364..097dfc6 100755
--- a/etc/scripts/apidocs.sh
+++ b/etc/scripts/apidocs.sh
@@ -1,3 +1,3 @@
 #!/bin/bash
 
-mvn -U -V -B clean install -Ppre-release -pl :apidocs -am -DskipTests
\ No newline at end of file
+mvn -U -V -B clean install -Ppre-release -Pstaging -pl :apidocs -am -DskipTests
\ No newline at end of file
diff --git a/etc/scripts/checkstyle.sh b/etc/scripts/checkstyle.sh
index ad36942..4afc1a9 100755
--- a/etc/scripts/checkstyle.sh
+++ b/etc/scripts/checkstyle.sh
@@ -1,3 +1,3 @@
 #!/bin/bash
 
-mvn -V -U -B  checkstyle:checkstyle-aggregate -Dcheckstyle.output.format="plain" -Dcheckstyle.output.file=checkstyle.log
\ No newline at end of file
+mvn -V -U -B  -Pstaging checkstyle:checkstyle-aggregate -Dcheckstyle.output.format="plain" -Dcheckstyle.output.file=checkstyle.log
\ No newline at end of file
diff --git a/examples/NOTICE.md b/examples/NOTICE.md
index 9455df8..ab5da5f 100644
--- a/examples/NOTICE.md
+++ b/examples/NOTICE.md
@@ -37,7 +37,7 @@
 * Project: http://aopalliance.sourceforge.net
 * Copyright: Material in the public domain is not protected by copyright
 
-Bean Validation API 3.1.0-M1
+Bean Validation API 3.1.0
 * License: Apache License, 2.0
 * Project: https://beanvalidation.org/3.0/
 * Copyright: 2009, Red Hat, Inc. and/or its affiliates, and individual contributors
diff --git a/ext/bean-validation/pom.xml b/ext/bean-validation/pom.xml
index 941031b..76b0b2a 100644
--- a/ext/bean-validation/pom.xml
+++ b/ext/bean-validation/pom.xml
@@ -95,6 +95,24 @@
             <artifactId>jakarta.validation-api</artifactId>
         </dependency>
         <dependency>
+            <groupId>jakarta.xml.bind</groupId>
+            <artifactId>jakarta.xml.bind-api</artifactId>
+            <optional>true</optional>
+        </dependency>
+        <dependency>
+            <groupId>jakarta.enterprise</groupId>
+            <artifactId>jakarta.enterprise.cdi-api</artifactId>
+            <optional>true</optional>
+        </dependency>
+        <dependency>
+            <groupId>org.glassfish.jersey.ext.cdi</groupId>
+            <artifactId>jersey-cdi1x</artifactId>
+            <version>${project.version}</version>
+            <optional>true</optional>
+        </dependency>
+
+<!--              Runtime dependencies to be used       -->
+        <dependency>
             <groupId>org.hibernate.validator</groupId>
             <artifactId>hibernate-validator</artifactId>
             <exclusions>
@@ -117,24 +135,6 @@
             <artifactId>jboss-logging</artifactId>
             <version>${jboss.logging.version}</version>
         </dependency>
-        <dependency>
-            <groupId>jakarta.xml.bind</groupId>
-            <artifactId>jakarta.xml.bind-api</artifactId>
-            <optional>true</optional>
-        </dependency>
-        <dependency>
-            <groupId>jakarta.enterprise</groupId>
-            <artifactId>jakarta.enterprise.cdi-api</artifactId>
-            <optional>true</optional>
-        </dependency>
-        <dependency>
-            <groupId>org.glassfish.jersey.ext.cdi</groupId>
-            <artifactId>jersey-cdi1x</artifactId>
-            <version>${project.version}</version>
-            <optional>true</optional>
-        </dependency>
-
-
         <!-- java-el related dependencies are in scope "provided" in hibernate-validator -->
         <dependency>
             <groupId>jakarta.el</groupId>
diff --git a/media/moxy/pom.xml b/media/moxy/pom.xml
index 997c627..1e8df0a 100644
--- a/media/moxy/pom.xml
+++ b/media/moxy/pom.xml
@@ -109,11 +109,12 @@
             <artifactId>parsson</artifactId>
         </dependency>
         <dependency>
-            <groupId>org.ow2.asm</groupId>
-            <artifactId>asm</artifactId>
-            <version>${asm.version}</version>
+            <groupId>org.eclipse.persistence</groupId>
+            <artifactId>org.eclipse.persistence.asm</artifactId>
+            <version>${moxy.asm.version}</version>
         </dependency>
 
+
         <dependency>
             <groupId>jakarta.xml.bind</groupId>
             <artifactId>jakarta.xml.bind-api</artifactId>
diff --git a/pom.xml b/pom.xml
index 08c6cbd..ada126d 100644
--- a/pom.xml
+++ b/pom.xml
@@ -2173,7 +2173,6 @@
         <servlet4.version>4.0.3</servlet4.version>
         <servlet6.version>6.1.0-M2</servlet6.version>
 
-        <simple.version>6.0.1</simple.version>
         <slf4j.version>2.0.13</slf4j.version>
         <spring6.version>6.0.18</spring6.version>
         <testng.version>7.9.0</testng.version>
@@ -2191,9 +2190,9 @@
         <graalvm.version>20.3.14</graalvm.version>
 
         <!-- do not need CQs (below this line till the end of version properties)-->
-        <gf.impl.version>7.0.13</gf.impl.version>
+        <gf.impl.version>8.0.0-JDK17-M6</gf.impl.version>
         <!-- Jakartified -->
-        <cdi.api.version>4.1.0.RC1</cdi.api.version>
+        <cdi.api.version>4.1.0</cdi.api.version>
         <cdi.osgi.version>jakarta.enterprise.*;version="[4.0,5)"</cdi.osgi.version>
         <ejb.version>4.0.1</ejb.version>
         <grizzly2.version>4.0.2</grizzly2.version>
@@ -2202,37 +2201,38 @@
         <hk2.version>4.0.0-M1</hk2.version>
         <hk2.osgi.version>org.glassfish.hk2.*;version="[4.0,5)"</hk2.osgi.version>
         <hk2.jvnet.osgi.version>org.jvnet.hk2.*;version="[4.0,5)"</hk2.jvnet.osgi.version>
-        <hk2.config.version>7.0.4</hk2.config.version>
+        <hk2.config.version>8.0.0-JDK17-M6</hk2.config.version>
         <jsp.version>4.0.0-M2</jsp.version>
         <jstl.version>3.0.0</jstl.version>
         <jta.api.version>2.0.1</jta.api.version>
         <istack.commons.runtime.version>4.1.2</istack.commons.runtime.version>
         <jakarta.activation-api.version>2.1.3</jakarta.activation-api.version>
         <jakarta.activation.version>2.0.2</jakarta.activation.version>
-        <jakarta.el.version>6.0.0-RC1</jakarta.el.version>
-        <jakarta.el.impl.version>5.0.0</jakarta.el.impl.version>
+        <jakarta.el.version>5.0.1</jakarta.el.version> <!-- el6 does not work with OSGi with expressly 5 -->
+        <jakarta.el.impl.version>5.0.0</jakarta.el.impl.version> <!-- EE11 expressly 6 does not work with EE10 BV 8.0.1 (OSGi) -->
         <jakarta.annotation.osgi.version>jakarta.annotation.*;version="[3.0,4)"</jakarta.annotation.osgi.version>
-        <jakarta.annotation.version>3.0.0-M1</jakarta.annotation.version>
+        <jakarta.annotation.version>3.0.0</jakarta.annotation.version>
         <jakarta.decorator.osgi.version>jakarta.decorator.*;version="[4.0,5)"</jakarta.decorator.osgi.version> <!-- CDI -->
         <jakarta.inject.version>2.0.1</jakarta.inject.version>
-        <jakarta.interceptor.version>2.2.0-M1</jakarta.interceptor.version>
+        <jakarta.interceptor.version>2.2.0</jakarta.interceptor.version>
         <jakarta.jsonp.version>2.1.3</jakarta.jsonp.version>
-        <jakarta.persistence.version>3.1.0</jakarta.persistence.version>
-        <jakarta.validation.api.version>3.1.0-M1</jakarta.validation.api.version>
+        <jakarta.persistence.version>3.2.0</jakarta.persistence.version>
+        <jakarta.validation.api.version>3.1.0</jakarta.validation.api.version>
         <jakarta.jaxb.api.version>4.0.2</jakarta.jaxb.api.version>
         <jaxb.ri.version>4.0.5</jaxb.ri.version>
-        <jaxrs.api.spec.version>3.1</jaxrs.api.spec.version>
-        <jaxrs.api.impl.version>3.1.0</jaxrs.api.impl.version>
+        <jaxrs.api.spec.version>4.0.0</jaxrs.api.spec.version>
+        <jaxrs.api.impl.version>4.0.0</jaxrs.api.impl.version>
         <jakarta.rest.osgi.version>jakarta.ws.rs;version="[3.1,5)",jakarta.ws.rs.client;version="[3.1,5)",jakarta.ws.rs.container;version="[3.1,5)",jakarta.ws.rs.core;version="[3.1,5)",jakarta.ws.rs.ext;version="[3.1,5)",jakarta.ws.rs.sse;version="[3.1,5)"</jakarta.rest.osgi.version>
         <jetty.osgi.version>org.eclipse.jetty.*;version="[11,15)"</jetty.osgi.version>
-        <jetty.version>12.0.7</jetty.version>
+        <jetty.version>12.0.9</jetty.version>
         <jetty9.version>9.4.54.v20240208</jetty9.version>
-        <jetty11.version>11.0.20</jetty11.version>
+        <jetty11.version>11.0.21</jetty11.version>
         <jetty.plugin.version>12.0.8</jetty.plugin.version>
         <jsonb.api.version>3.0.1</jsonb.api.version>
-        <jsonp.ri.version>1.1.5</jsonp.ri.version>
-        <jsonp.jaxrs.version>1.1.5</jsonp.jaxrs.version>
-        <moxy.version>4.0.2</moxy.version>
+        <jsonp.ri.version>1.1.6</jsonp.ri.version>
+        <jsonp.jaxrs.version>1.1.6</jsonp.jaxrs.version>
+        <moxy.version>5.0.0-B02</moxy.version>
+        <moxy.asm.version>9.7.0</moxy.asm.version>
         <yasson.version>3.0.3</yasson.version>
         <!-- END of Jakartified -->
 
diff --git a/tests/osgi/functional/pom.xml b/tests/osgi/functional/pom.xml
index b8f067c..824d6f2 100644
--- a/tests/osgi/functional/pom.xml
+++ b/tests/osgi/functional/pom.xml
@@ -71,7 +71,6 @@
                     <reuseForks>false</reuseForks>
                     <enableAssertions>false</enableAssertions>
                     <excludes>
-                        <exclude>**/BeanValidationTest*</exclude>
                         <exclude>**/JsonProcessingTest*</exclude>
                         <exclude>**/JaxRsRiBundleTest*</exclude>
                     </excludes>
diff --git a/tests/release-test/pom.xml b/tests/release-test/pom.xml
index fee961a..03d4781 100644
--- a/tests/release-test/pom.xml
+++ b/tests/release-test/pom.xml
@@ -55,6 +55,7 @@
                     <includes>
                         <include>**/ArchetypesTest</include>
                         <include>**/NoticeFilesTest</include>
+                        <include>**/MoxyAsmTest</include>
                     </includes>
                 </configuration>
             </plugin>
diff --git a/tests/release-test/src/test/java/org/glassfish/jersey/test/artifacts/MoxyAsmTest.java b/tests/release-test/src/test/java/org/glassfish/jersey/test/artifacts/MoxyAsmTest.java
new file mode 100644
index 0000000..13b0210
--- /dev/null
+++ b/tests/release-test/src/test/java/org/glassfish/jersey/test/artifacts/MoxyAsmTest.java
@@ -0,0 +1,51 @@
+/*
+ * Copyright (c) 2022, 2024 Oracle and/or its affiliates. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v. 2.0, which is available at
+ * http://www.eclipse.org/legal/epl-2.0.
+ *
+ * This Source Code may also be made available under the following Secondary
+ * Licenses when the conditions for such availability set forth in the
+ * Eclipse Public License v. 2.0 are satisfied: GNU General Public License,
+ * version 2 with the GNU Classpath Exception, which is available at
+ * https://www.gnu.org/software/classpath/license.html.
+ *
+ * SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
+ */
+
+package org.glassfish.jersey.test.artifacts;
+
+import org.apache.maven.model.Dependency;
+import org.apache.maven.model.Model;
+import org.junit.Assert;
+import org.junit.Test;
+
+public class MoxyAsmTest {
+    @Test
+    public void testAsmInMoxy() throws Exception {
+        String moxyPomFile = "../../media/moxy/pom.xml";
+        Model moxyPom = MavenUtil.getModelFromFile(moxyPomFile);
+        final Dependency moxyAsmDependency = moxyPom.getDependencies().stream()
+                .filter(dependency -> dependency.getArtifactId().equals("org.eclipse.persistence.asm"))
+                .findFirst().get();
+        Model projectPom = MavenUtil.getModelFromFile("../../pom.xml");
+        final String asmVersion = projectPom.getProperties().getProperty("asm.version");
+        final String moxyAsmVersion = findVersionInModel(moxyAsmDependency.getVersion(), projectPom);
+
+        final String lastTwo = moxyAsmVersion.substring(moxyAsmVersion.length() - 2);
+        final String msg = "org.eclipse.persistence.asm version " + moxyAsmVersion
+                + " differs from asm version " + asmVersion + " in /media/moxy/pom.xml";
+        Assert.assertEquals(msg, asmVersion + lastTwo, moxyAsmVersion);
+        System.out.println("Found expected Moxy ASM version " + moxyAsmVersion);
+    }
+
+    private static String findVersionInModel(String version, Model model) {
+        if (version.startsWith("${")) {
+            String _version = version.substring(2, version.length() - 1);
+            return model.getProperties().getProperty(_version);
+        } else {
+            return version;
+        }
+    }
+}