Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[doc] Document Ant Task parameter threads #3807

Merged
merged 2 commits into from Feb 25, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 8 additions & 0 deletions docs/pages/pmd/userdocs/tools/ant.md
Expand Up @@ -122,6 +122,14 @@ The examples below won't repeat this taskdef element, as this is always required
</td>
<td>No</td>
</tr>
<tr>
<td>threads</td>
<td>
Sets the number of threads used by PMD. Set threads to <code>0</code> to disable multi-threading processing.
Default: 1
</td>
<td>No</td>
</tr>
</table>


Expand Down
1 change: 1 addition & 0 deletions docs/pages/release_notes.md
Expand Up @@ -20,6 +20,7 @@ This is a {{ site.pmd.release_type }} release.
* [#3427](https://github.com/pmd/pmd/issues/3427): \[core] Stop printing CLI usage text when exiting due to invalid parameters
* doc
* [#2502](https://github.com/pmd/pmd/issues/2502): \[doc] Add floating table-of-contents (toc) on the right
* [#3807](https://github.com/pmd/pmd/pull/3807): \[doc] Document Ant Task parameter `threads`
* java
* [#3698](https://github.com/pmd/pmd/issues/3697): \[java] Parsing error with try-with-resources and qualified resource
* java-codestyle
Expand Down
Expand Up @@ -30,7 +30,7 @@ public class PMDTask extends Task {
private String rulesetFiles;
private boolean noRuleSetCompatibility;
private String encoding;
private int threads;
private int threads = 1; // same default as in PMDParameters (CLI)
private int minimumPriority;
private int maxRuleViolations = 0;
private String failuresPropertyName;
Expand Down
Expand Up @@ -60,7 +60,7 @@ public class PMDParameters {

@Parameter(names = { "--threads", "-threads", "-t" }, description = "Sets the number of threads used by PMD.",
validateWith = PositiveInteger.class)
private int threads = 1;
private int threads = 1; // see also default in PMDTask (Ant)

@Parameter(names = { "--benchmark", "-benchmark", "-b" },
description = "Benchmark mode - output a benchmark report upon completion; default to System.err.")
Expand Down