gnodet commented on code in PR #13930:
URL: https://github.com/apache/maven/pull/13930#discussion_r4528355962
##########
api/maven-api-model/src/main/mdo/maven.mdo:
##########
@@ -1233,7 +1233,7 @@
</description>
<type>String</type>
</field>
- <field>
+ <field
xsd.suggestions="jar,pom,war,ear,ejb,rar,par,ejb-client,test-jar,maven-plugin">
Review Comment:
Missing most constants defined in `org.apache.maven.api.Type`. The list
currently has 10 values; the API defines 14 — `bom`, `fatjar`, `classpath-jar`,
`modular-jar`, `processor`, `classpath-processor`, `modular-processor`,
`java-source`, `javadoc`, and `test-java-source` are absent.
```suggestion
<field
xsd.suggestions="pom,bom,jar,fatjar,classpath-jar,modular-jar,processor,classpath-processor,modular-processor,java-source,javadoc,maven-plugin,test-jar,test-java-source,war,ear,ejb,rar,par,ejb-client">
```
##########
api/maven-api-model/src/main/mdo/maven.mdo:
##########
@@ -1266,7 +1266,7 @@
<type>String</type>
<required>false</required>
</field>
- <field>
+ <field xsd.enumerations="compile,provided,runtime,test,system,import">
Review Comment:
`import` is not a `DependencyScope` id — it's a special value handled by the
model builder for BOM imports, not an enum constant. Also missing the Maven 4
scopes: `compile-only`, `test-only`, `test-runtime`, `none`.
```suggestion
<field
xsd.enumerations="none,compile-only,compile,runtime,provided,test-only,test,test-runtime,system,import">
```
(`import` is kept since it is widely used even if it's not a
`DependencyScope` constant; the new Maven 4 scopes should be listed alongside
the Maven 3 ones.)
##########
api/maven-api-model/src/main/mdo/maven.mdo:
##########
@@ -156,7 +156,7 @@
<description>The current version of the artifact produced by this
project.</description>
<type>String</type>
</field>
- <field>
+ <field xsd.suggestions="jar,pom,war,ear,ejb,rar,par,maven-plugin">
Review Comment:
Missing `bom` — it is a valid packaging type (backed by `Type.BOM`).
```suggestion
<field
xsd.suggestions="jar,pom,bom,war,ear,ejb,rar,par,maven-plugin">
```
##########
api/maven-api-plugin/src/main/mdo/plugin.mdo:
##########
@@ -179,7 +179,7 @@ under the License.
<defaultValue>java</defaultValue>
<description>The implementation language for this Mojo (java,
beanshell, etc.).</description>
</field>
- <field>
+ <field
xsd.suggestions="validate,initialize,generate-sources,process-sources,generate-resources,process-resources,compile,process-classes,generate-test-sources,process-test-sources,generate-test-resources,process-test-resources,test-compile,process-test-classes,test,prepare-package,package,pre-integration-test,integration-test,post-integration-test,verify,install,deploy,pre-clean,clean,post-clean,pre-site,site,post-site,site-deploy">
Review Comment:
Same issue as in `maven.mdo`: these are Maven 3 phase names. Should use
`Lifecycle.Phase` constants + `before:`/`after:` qualifiers.
```suggestion
<field
xsd.suggestions="all,each,build,initialize,validate,sources,resources,compile,ready,package,verify,unit-test,test-sources,test-resources,test-compile,test,integration-test,install,deploy,clean,before:,after:">
```
##########
api/maven-api-model/src/main/mdo/maven.mdo:
##########
@@ -2833,7 +2833,7 @@
<description>The identifier of this execution for labelling the
goals during the build,
and for matching executions to merge during inheritance and
profile injection.</description>
</field>
- <field>
+ <field
xsd.suggestions="validate,initialize,generate-sources,process-sources,generate-resources,process-resources,compile,process-classes,generate-test-sources,process-test-sources,generate-test-resources,process-test-resources,test-compile,process-test-classes,test,prepare-package,package,pre-integration-test,integration-test,post-integration-test,verify,install,deploy,pre-clean,clean,post-clean,pre-site,site,post-site,site-deploy">
Review Comment:
These are Maven 3 phase names. For Maven 4 the canonical phase names come
from `org.apache.maven.api.Lifecycle.Phase` constants, plus the `before:` /
`after:` qualifiers from `Lifecycle.BEFORE` / `Lifecycle.AFTER`.
```suggestion
<field
xsd.suggestions="all,each,build,initialize,validate,sources,resources,compile,ready,package,verify,unit-test,test-sources,test-resources,test-compile,test,integration-test,install,deploy,clean,before:,after:">
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]