[ 
https://issues.apache.org/jira/browse/MPMD-379?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17835025#comment-17835025
 ] 

ASF GitHub Bot commented on MPMD-379:
-------------------------------------

michael-o commented on code in PR #144:
URL: https://github.com/apache/maven-pmd-plugin/pull/144#discussion_r1556376942


##########
src/it/MPMD-379-JDK21/invoker.properties:
##########
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+invoker.java.version = 1.8+
+
+# available toolchains under linux:
+# 
https://github.com/apache/infrastructure-p6/blob/production/modules/build_nodes/files/toolchains.xml
+
+# the jdk toolchain "21:openjdk" is selected in pom.xml
+invoker.toolchain.jdk.version = 21
+invoker.toolchain.jdk.vendor = openjdk

Review Comment:
   Then there is no need to restrict the vendor if any vendor will do. I guess 
a lot of people will also use Zulu which will not run here.



##########
src/main/java/org/apache/maven/plugins/pmd/PmdReport.java:
##########
@@ -63,16 +63,19 @@
 @Mojo(name = "pmd", threadSafe = true, requiresDependencyResolution = 
ResolutionScope.TEST)
 public class PmdReport extends AbstractPmdReport {
     /**
-     * The target JDK to analyze based on. Should match the source used in the 
compiler plugin. Valid values
-     * with the default PMD version are
+     * The target JDK to analyze based on. Should match the source used in the 
compiler plugin.
+     * Valid values depend on the used PMD version. With the default PMD 
version valid values are
      * currently <code>1.3</code>, <code>1.4</code>, <code>1.5</code>, 
<code>1.6</code>, <code>1.7</code>,
      * <code>1.8</code>, <code>9</code>, <code>10</code>, <code>11</code>, 
<code>12</code>, <code>13</code>,
      * <code>14</code>, <code>15</code>, <code>16</code>, <code>17</code>, 
<code>18</code>, <code>19</code>,
-     * and <code>20</code>.
+     * <code>20</code>, <code>21</code>, and <code>22</code>.

Review Comment:
   Let's do so.





> Upgrade to use PMD 7.0.0 by default
> -----------------------------------
>
>                 Key: MPMD-379
>                 URL: https://issues.apache.org/jira/browse/MPMD-379
>             Project: Maven PMD Plugin
>          Issue Type: Improvement
>          Components: CPD, PMD
>            Reporter: Andreas Dangel
>            Assignee: Andreas Dangel
>            Priority: Major
>             Fix For: next-release
>
>
> Add support for the new major version of PMD.
> This gives support for analyzing Java 21 code.
> The upgrade from PMD 6 to PMD 7 is a major upgrade, that might impact 
> end-users, if they use custom rulesets (see 
> [https://maven.apache.org/plugins/maven-pmd-plugin/examples/usingRuleSets.html])
>  or if they override the dependencies to upgrade PMD at runtime and currently 
> use PMD 6.x (see 
> [https://maven.apache.org/plugins/maven-pmd-plugin/examples/upgrading-PMD-at-runtime.html]).
>  
> Most likely, end-users have to review their rulesets and migrate them to PMD 
> 7. Rules might have been renamed or replaced. See 
> [https://docs.pmd-code.org/latest/pmd_release_notes_pmd7.html] and 
> [https://docs.pmd-code.org/latest/pmd_userdocs_migrating_to_pmd7.html] .
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to