Skip to content

Commit a2bb761

Browse files
committed
[JBMETA-440]: Use urn instead of URL for jboss namespaces.
* Replacing http://www.jboss.com/xml/ns/jakartaee with urn:jboss:jakartaee:1.0 * Fixing a bunch of leftovers in comments Signed-off-by: Emmanuel Hugonnet <ehugonne@redhat.com>
1 parent 4018315 commit a2bb761

File tree

14 files changed

+47
-48
lines changed

14 files changed

+47
-48
lines changed

appclient/src/main/resources/schema/jboss-client_9_0.xsd

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@
1818
-->
1919
<xsd:schema xmlns="http://www.w3.org/2001/XMLSchema"
2020
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
21-
xmlns:jboss="https://www.jboss.com/xml/ns/jakartaee"
22-
targetNamespace="https://www.jboss.com/xml/ns/jakartaee"
21+
xmlns:jboss="urn:jboss:jakartaee:1.0"
22+
targetNamespace="urn:jboss:jakartaee:1.0"
2323
version="9.0"
2424
elementFormDefault="qualified"
2525
>
@@ -28,29 +28,29 @@
2828
<xsd:documentation>
2929
<![CDATA[
3030
31-
This is the XML Schema for the JBoss 8.0 application client deployment descriptor.
31+
This is the XML Schema for the JBoss 9.0 application client deployment descriptor.
3232
The deployment descriptor must be named "META-INF/jboss-client.xml" in
3333
the application client's jar file. All the application client deployment descriptors must indicate
34-
the JBoss schema by using the Java EE namespace:
34+
the JBoss schema by using the Jakarta EE namespace:
3535
36-
https://www.jboss.com/xml/ns/jakartaee
36+
urn:jboss:jakartaee:1.0
3737
3838
and by indicating the version of the schema by
3939
using the version attribute as shown below:
4040
41-
<jboss-client xmlns="https://www.jboss.com/xml/ns/jakartaee"
41+
<jboss-client xmlns="urn:jboss:jakartaee:1.0"
4242
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
43-
xsi:schemaLocation="https://www.jboss.com/xml/ns/jakartaee
44-
https://www.jboss.org/j2ee/schema/jboss-client_9_0.xsd"
45-
version="8.1">
43+
xsi:schemaLocation="urn:jboss:jakartaee:1.0
44+
https://www.jboss.org/schema/jbossas/jboss-client_9_0.xsd"
45+
version="9.0">
4646
...
4747
</jboss-client>
4848
4949
The instance documents may indicate the published version of
5050
the schema using the xsi:schemaLocation attribute for the
51-
Java EE namespace with the following location:
51+
Jakarta EE namespace with the following location:
5252
53-
https://www.jboss.org/j2ee/schema/jboss-client_9_0.xsd
53+
https://www.jboss.org/schema/jbossas/jboss-client_9_0.xsd
5454
5555
]]>
5656
</xsd:documentation>

appclient/src/test/java/org/jboss/test/metadata/appclient/AppclientSpecDescriptorTestCase.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public class AppclientSpecDescriptorTestCase extends SpecDescriptorTestCase {
3838
@Parameters
3939
public static List<Object[]> parameters() {
4040
// The spec descriptor should be guarded in schema
41-
return Arrays.asList(new Object[][]{{"schema/application-client_6.xsd"},{"schema/application-client_7.xsd"},{"schema/application-client_8.xsd"},{"schema/application-client_9.xsd"}});
41+
return Arrays.asList(new Object[][]{{"schema/application-client_6.xsd"},{"schema/application-client_7.xsd"},{"schema/application-client_8.xsd"},{"schema/application-client_9.xsd"},{"schema/application-client_10.xsd"}});
4242
}
4343

4444
public AppclientSpecDescriptorTestCase(String xsd) {

common/src/main/java/org/jboss/metadata/javaee/spec/JavaEEMetaDataConstants.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ public interface JavaEEMetaDataConstants {
5959
/**
6060
* The jboss jakartaee namespaces
6161
*/
62-
String JBOSS_JAKARTAEE_NS = "http://www.jboss.com/xml/ns/jakartaee";
62+
String JBOSS_JAKARTAEE_NS = "urn:jboss:jakartaee:1.0";
6363

6464
/**
6565
* The jbosscmp-jdbc namespace

common/src/main/resources/schema/jboss-common_9_0.xsd

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@
1717
~ limitations under the License.
1818
-->
1919
<xsd:schema xmlns="http://www.w3.org/2001/XMLSchema"
20-
targetNamespace="http://www.jboss.com/xml/ns/jakartaee"
20+
targetNamespace="urn:jboss:jakartaee:1.0"
2121
xmlns:jakartaee="https://jakarta.ee/xml/ns/jakartaee"
22-
xmlns:jboss="http://www.jboss.com/xml/ns/jakartaee"
22+
xmlns:jboss="urn:jboss:jakartaee:1.0"
2323
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
2424
elementFormDefault="qualified"
2525
attributeFormDefault="unqualified"
@@ -31,7 +31,7 @@
3131
This XML Schema defines types, elements and model groups that common to all application-specific JBoss schemas.
3232
The target namespace is
3333
34-
http://www.jboss.com/xml/ns/jakartaaee
34+
urn:jboss:jakartaee:1.0
3535
3636
Online URL https://www.jboss.org/schema/jbossas/jboss-common_9_0.xsd
3737
]]>

ear/src/main/java/org/jboss/metadata/ear/parser/jboss/Namespace.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public enum Namespace {
3131
// must be first
3232
UNKNOWN(null),
3333
JBOSS("http://www.jboss.com/xml/ns/javaee"),
34-
JBOSS_JAKARTA("http://www.jboss.com/xml/ns/jakartaee"),
34+
JBOSS_JAKARTA("urn:jboss:jakartaee:1.0"),
3535
SPEC("http://java.sun.com/xml/ns/javaee"),
3636
SPEC_7_0("http://xmlns.jcp.org/xml/ns/javaee"),
3737
JAKARTAEE("https://jakarta.ee/xml/ns/jakartaee");

ear/src/main/java/org/jboss/metadata/ear/spec/EarVersion.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public enum EarVersion {
4242
APP_9_0("https://jakarta.ee/xml/ns/jakartaee/application_9.xsd", "9.0", JavaEEVersion.V9),
4343
APP_10_0("https://jakarta.ee/xml/ns/jakartaee/application_10.xsd", "10.0", JavaEEVersion.V10);
4444

45-
private static final Map<String, EarVersion> bindings = new HashMap<String, EarVersion>();
45+
private static final Map<String, EarVersion> bindings = new HashMap<>();
4646

4747
private final String location;
4848
private final String version;

ear/src/main/resources/schema/jboss-app_9_0.xsd

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -19,36 +19,36 @@
1919
<xs:schema xmlns="urn:jboss:jakartaee:1.0"
2020
xmlns:xs="http://www.w3.org/2001/XMLSchema"
2121
xmlns:jakartaee="https://jakarta.ee/xml/ns/jakartaee"
22-
xmlns:jboss="http://www.jboss.com/xml/ns/jakartaee"
23-
targetNamespace="http://www.jboss.com/xml/ns/jakartaee"
22+
xmlns:jboss="urn:jboss:jakartaee:1.0"
23+
targetNamespace="urn:jboss:jakartaee:1.0"
2424
version="9.0"
2525
elementFormDefault="qualified">
2626

2727
<xs:annotation>
2828
<xs:documentation>
2929
<![CDATA[
3030
31-
This is the XML Schema for the JBoss AS7 EAR application deployment descriptor.
31+
This is the XML Schema for the JBoss EAR application deployment descriptor.
3232
The deployment descriptor must be named "jboss-app.xml" and placed in the
3333
.ear/META-INF folder. All the descriptors must indicate
34-
the JBoss schema by using the Java EE namespace:
34+
the JBoss schema by using the Jakarta EE namespace:
3535
3636
urn:jboss:jakartaee:1.0
3737
3838
and by indicating the version of the schema by
3939
using the version attribute as shown below:
4040
41-
<jboss-app xmlns="http://www.jboss.com/xml/ns/jakartaee"
41+
<jboss-app xmlns="urn:jboss:jakartaee:1.0"
4242
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
43-
version="8.1">
43+
version="9.0">
4444
...
4545
</jboss-app>
4646
4747
The instance documents may indicate the published version of
4848
the schema using the xsi:schemaLocation attribute for the
49-
Java EE namespace with the following location:
49+
Jakarta EE namespace with the following location:
5050
51-
https://www.jboss.org/schema/jbossas/jboss-app_10_0.xsd
51+
https://www.jboss.org/schema/jbossas/jboss-app_9_0.xsd
5252
5353
]]>
5454
</xs:documentation>

ear/src/test/resources/org/jboss/test/metadata/ear/Ear10xEverything_testEverything.xml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<application xmlns="https://jakarta.ee/xml/ns/jakartaee"
33
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4-
xsi:schemaLocation="https://jakarta.ee/xml/ns/jakartaee
5-
https://jakarta.ee/xml/ns/jakartaee/application_10.xsd"
4+
xsi:schemaLocation="https://jakarta.ee/xml/ns/jakartaee https://jakarta.ee/xml/ns/jakartaee/application_10.xsd"
65
version="10" id="application-test-everything">
76

87
<application-name>ApplicationName</application-name>
@@ -926,8 +925,8 @@
926925
<description>appManagedExecutor1-desc</description>
927926
<name>appManagedExecutor1-name</name>
928927
<context-service-ref>appManagedExecutor1-contextServiceRef</context-service-ref>
929-
<hung-task-threshold>1</hung-task-threshold>
930928
<max-async>1</max-async>
929+
<hung-task-threshold>1</hung-task-threshold>
931930
<property id="appManagedExecutor1Property1-id">
932931
<name>appManagedExecutor1Property1Name</name>
933932
<value>appManagedExecutor1Property1Value</value>
@@ -941,8 +940,8 @@
941940
<description>appManagedExecutor2-desc</description>
942941
<name>appManagedExecutor2-name</name>
943942
<context-service-ref>appManagedExecutor2-contextServiceRef</context-service-ref>
944-
<hung-task-threshold>2</hung-task-threshold>
945943
<max-async>2</max-async>
944+
<hung-task-threshold>2</hung-task-threshold>
946945
<property id="appManagedExecutor2Property1-id">
947946
<name>appManagedExecutor2Property1Name</name>
948947
<value>appManagedExecutor2Property1Value</value>
@@ -961,8 +960,8 @@
961960
<description>appManagedScheduledExecutor1-desc</description>
962961
<name>appManagedScheduledExecutor1-name</name>
963962
<context-service-ref>appManagedScheduledExecutor1-contextServiceRef</context-service-ref>
964-
<hung-task-threshold>1</hung-task-threshold>
965963
<max-async>1</max-async>
964+
<hung-task-threshold>1</hung-task-threshold>
966965
<property id="appManagedScheduledExecutor1Property1-id">
967966
<name>appManagedScheduledExecutor1Property1Name</name>
968967
<value>appManagedScheduledExecutor1Property1Value</value>
@@ -976,8 +975,8 @@
976975
<description>appManagedScheduledExecutor2-desc</description>
977976
<name>appManagedScheduledExecutor2-name</name>
978977
<context-service-ref>appManagedScheduledExecutor2-contextServiceRef</context-service-ref>
979-
<hung-task-threshold>2</hung-task-threshold>
980978
<max-async>2</max-async>
979+
<hung-task-threshold>2</hung-task-threshold>
981980
<property id="appManagedScheduledExecutor2Property1-id">
982981
<name>appManagedScheduledExecutor2Property1Name</name>
983982
<value>appManagedScheduledExecutor2Property1Value</value>

ear/src/test/resources/org/jboss/test/metadata/ear/JBossApp9xEverything_testEverything.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@
2121
~ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
2222
-->
2323

24-
<jboss-app xmlns="http://www.jboss.com/xml/ns/jakartaee"
24+
<jboss-app xmlns="urn:jboss:jakartaee:1.0"
2525
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
26-
xsi:schemaLocation="http://www.jboss.com/xml/ns/jakartaee https://www.jboss.org/schema/jbossas/jboss-app_9_0.xsd"
26+
xsi:schemaLocation="urn:jboss:jakartaee:1.0 https://www.jboss.org/schema/jbossas/jboss-app_9_0.xsd"
2727
version="9.0"
2828
id="jboss-app-id">
2929

ejb/src/main/java/org/jboss/metadata/ejb/parser/jboss/ejb3/Namespace.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public enum Namespace {
3131
// must be first
3232
UNKNOWN(null),
3333
JBOSS("http://www.jboss.com/xml/ns/javaee"),
34-
JBOSS_JAKARTA("http://www.jboss.com/xml/ns/jakartaee"),
34+
JBOSS_JAKARTA("urn:jboss:jakartaee:1.0"),
3535
SPEC("http://java.sun.com/xml/ns/javaee"),
3636
SPEC_7_0("http://xmlns.jcp.org/xml/ns/javaee"),
3737
JAKARTAEE("https://jakarta.ee/xml/ns/jakartaee");
@@ -49,7 +49,7 @@ public String getUriString() {
4949
private static final Map<String, Namespace> MAP;
5050

5151
static {
52-
final Map<String, Namespace> map = new HashMap<String, Namespace>();
52+
final Map<String, Namespace> map = new HashMap<>();
5353
for (Namespace namespace : values()) {
5454
final String name = namespace.getUriString();
5555
if (name != null) map.put(name, namespace);

0 commit comments

Comments
 (0)