Docs xmlnode deprecations followup#11576
Conversation
7d8333e to
b159b3d
Compare
|
Hi @desruisseaux , kindly requesting a review when time permits. |
|
Friendly reminder — this PR has been idle for a few weeks. |
| String CHILDREN_COMBINATION_MODE_ATTRIBUTE = XmlService.CHILDREN_COMBINATION_MODE_ATTRIBUTE; | ||
|
|
||
| /** | ||
| * @deprecated since 4.0.0. |
There was a problem hiding this comment.
I don't know if we need to say "since 4.0.0." Will the annotation add this?
There was a problem hiding this comment.
Thanks for pointing that out. I’ve removed the redundant “since 4.0.0.” text from the comment and kept the version in the annotation only.
| Object inputLocation(); | ||
|
|
||
| // Deprecated methods that delegate to new ones | ||
| /** |
There was a problem hiding this comment.
I consider these deprecation mistaken and unnecessary, and would prefer to revert them all before release. The original method names were just fine
There was a problem hiding this comment.
This is an unrelated change that should not be in this PR
|
@elharo Thanks for the review. |
|
|
||
|
|
||
| /** | ||
| * @deprecated since 4.0.0. |
There was a problem hiding this comment.
The since 4.0.0 part in the comment is redundant with the since = "4.0.0" part in the annotation. The latter will be visible in the generated Javadoc.
There was a problem hiding this comment.
Thanks for pointing that out. I’ve removed the redundant “since 4.0.0.” text from the comment and kept the version in the annotation only.
| * @deprecated Use {@link #RESOURCES} instead. | ||
| */ | ||
| @Deprecated | ||
| @Deprecated(since = "4.0.0-alpha", forRemoval = false) |
There was a problem hiding this comment.
scratch that; this file should not be in this PR
There was a problem hiding this comment.
You’re right — this file was accidentally included from another PR. I’ve removed the Language.java changes so this PR now only contains the XmlNode updates.
| * @deprecated Use {@link #RESOURCES} instead. | ||
| */ | ||
| @Deprecated | ||
| @Deprecated(since = "4.0.0-alpha", forRemoval = false) |
There was a problem hiding this comment.
scratch that; this file should not be in this PR
gnodet
left a comment
There was a problem hiding this comment.
Claude Code on behalf of Guillaume Nodet
The deprecation Javadoc additions on XmlNode, Artifact, and Language look good overall. However, there is a compilation-breaking duplicate field, a typo, a stale Javadoc @param, and some whitespace nits. Also, this PR bundles a significant behavioral change in DefaultProjectManager (multi-module artifact-id relaxation) that goes well beyond "docs deprecation followup" -- that should be in a separate PR.
The DefaultProjectManager and DefaultSourceRoot changes are out of scope for a documentation PR and should be split out.
a2bb16b to
2e63c99
Compare
|
Hi @gnodet |
gnodet
left a comment
There was a problem hiding this comment.
Fully automatic review from Claude Code
Review of PR #11576 — Docs xmlnode deprecations followup
The PR is much improved from earlier iterations — the unrelated files (Language.java, DefaultSourceRoot, DefaultProjectManagerTest) are removed, the redundant since 4.0.0. text in Javadoc is cleaned up per reviewer feedback, and the @deprecated tags are consistently capitalized with trailing periods. Good work.
Two remaining issues:
1. Missing @deprecated Javadoc on getName() (consistency gap)
Every other deprecated getter method in this PR gets a @deprecated Javadoc added (getNamespaceUri, getPrefix, getValue, getAttributes, getAttribute, getChildren, getChild, getInputLocation), but getName() is the only one left without it. The comment // Deprecated methods that delegate to new ones was removed, but no replacement Javadoc was added. It should get the same treatment:
/**
* @deprecated Use {@link #name()} instead.
*/
@Deprecated(since = "4.0.0", forRemoval = true)
@Nonnull
default String getName() {
return name();
}2. Minor: removed blank line before getValue() (formatting inconsistency)
The blank line between getPrefix() and getValue() was removed, while blank lines between all other methods are preserved. This looks unintentional.
Everything else looks correct — the {@link} targets all resolve to real constants/methods in XmlService, and the scope of the PR is now properly focused on XmlNode only.
Thank you for review and guidance. I’ve updated the Javadocs and made the formatting consistent. Please review it and let me know if any changes need from my side |
This pull request completes the deprecation documentation for XmlNode
constants and methods by adding consistent Javadoc rationale and
explicit replacement references.
No functional behavior is changed.
Following this checklist to help us incorporate your
contribution quickly and easily:
Note that commits might be squashed by a maintainer on merge.
This may not always be possible but is a best-practice.
mvn verifyto make sure basic checks pass.A more thorough check will be performed on your pull request automatically.
If your pull request is about ~20 lines of code you don't need to sign an
Individual Contributor License Agreement if you are unsure
please ask on the developers list.
To make clear that you license your contribution under
the Apache License Version 2.0, January 2004
you have to acknowledge this by using the following check-box.