-
Notifications
You must be signed in to change notification settings - Fork 6.1k
8305406: Add @spec tags in java.base/java.* (part 2) #21326
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
Conversation
….java Co-authored-by: Daniel Jelinski <djelinski1@gmail.com>
|
👋 Welcome back hannesw! A progress list of the required criteria for merging this PR into |
|
@hns This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be: You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 334 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
Webrevs
|
|
One of the reasons for adding the javadoc |
|
Is "https://tools.ietf.org/html/rfc8103" considered external spec? It is mentioned in com.sun.crypto.provider.ChaCha20Poly1305Parameters class but not covered in this PR. Is there any additional condition for an external reference to be included? How about an external reference to a section of a specification? E.g. http://www.w3.org/TR/xmlenc-core/#sec-Alg-SymmetricKeyWrap in com.sun.crypto.provider.DESedeWrapCipher class which is also not covered by this PR. |
| * Security Appendix</a> | ||
| * of the <cite>Java Object Serialization Specification</cite> for more information. | ||
| * | ||
| * @spec serialization/index.html Java Object Serialization Specification |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe it's due to the reference is in the javadoc for a pkg private method?
That may be why Jon's automated update didn't pick it up, but note that this is an interface so getAlgorithm() is actually a public method. I'll add the @spec tag.
Valerie, The intent of This PR, and others that have preceded it, are mechanically derived by examining |
| * | ||
| * </ul> | ||
| * | ||
| * @spec security/standard-names.html Java Security Standard Algorithm Names |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about the other 2 under Package Specification (from line 49-53)? Does this PR need to cover them also?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same question applies for the java/security/interfaces/package-info.java file as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess the link for PKCS #8 would be https://www.rfc-editor.org/info/rfc5208 , but the doc comment says "November 1993", while the spec page says "May 2008", so maybe that should be updated as well. For the JCA Reference Guide, it's not clear to me it qualifies as a specification. So this and java/security/interfaces/package-info.java are cases that I think should be handled by the component maintainers.
| * @spec security/standard-names.html Java Security Standard Algorithm Names | ||
| * @spec https://www.rfc-editor.org/info/rfc5280 | ||
| * RFC 5280: Internet X.509 Public Key Infrastructure Certificate | ||
| * and Certificate Revocation List (CRL) Profile |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about RFC 2560 (line 39-40)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can add a @spec tag for RFC 2560 here. Possibly the mention in the description should also be converted to a link, but I think this PR should be limited to adding @spec tags.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for looking at this, Valerie. As Jon said in his comment, this PR is based on automated detection of @see and {@link} tags, and therefore not necessarily complete.
That said I will add @spec for those cases you pointed out that I think are unambigous (see inline comments). Others that I think need more consideration and possibly updates of other parts of the doc comments I would prefer to be handled by the component maintainers.
| * Security Appendix</a> | ||
| * of the <cite>Java Object Serialization Specification</cite> for more information. | ||
| * | ||
| * @spec serialization/index.html Java Object Serialization Specification |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe it's due to the reference is in the javadoc for a pkg private method?
That may be why Jon's automated update didn't pick it up, but note that this is an interface so getAlgorithm() is actually a public method. I'll add the @spec tag.
| * @spec security/standard-names.html Java Security Standard Algorithm Names | ||
| * @spec https://www.rfc-editor.org/info/rfc5280 | ||
| * RFC 5280: Internet X.509 Public Key Infrastructure Certificate | ||
| * and Certificate Revocation List (CRL) Profile |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can add a @spec tag for RFC 2560 here. Possibly the mention in the description should also be converted to a link, but I think this PR should be limited to adding @spec tags.
| * | ||
| * </ul> | ||
| * | ||
| * @spec security/standard-names.html Java Security Standard Algorithm Names |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess the link for PKCS #8 would be https://www.rfc-editor.org/info/rfc5208 , but the doc comment says "November 1993", while the spec page says "May 2008", so maybe that should be updated as well. For the JCA Reference Guide, it's not clear to me it qualifies as a specification. So this and java/security/interfaces/package-info.java are cases that I think should be handled by the component maintainers.
|
@valeriepeng I added two more I'm also uploading new API docs with the "External Specifications" page here: |
|
/author set @jonathan-gibbons |
|
@hns |
|
@hns |
|
@hns |
| * Java Security Standard Algorithm Names</a> document | ||
| * for information about standard algorithm names. | ||
| * | ||
| * @spec security/standard-names.html Java Security Standard Algorithm Names |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are more than 1 mentioning of the Java Security Standard Algorithm Names spec in this class. Do you know why only this one is covered by the @SPEC tag? Is it due to that the rest of the references contain "#" indicating a segment of the spec?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Never mind, I see that the scope is only about absolute URLs in one of the earlier replies.
I see. Thanks for the clarification. |
|
Thanks! /integrate |
|
Going to push as commit 873f8a6.
Your commit was automatically rebased without conflicts. |
Please review a doc update to add
@spectags to crypto and security APIs injava.base.This was authored and proposed as #13336 by @jonathan-gibbons as part of an effort to add
@spectags and an external specifications page to API documentation. The original PR was reviewed and approved, yet for some reason it was never integrated.Since I couldn't reopen Jon's PR I created a new pull request based the original commits. They still apply cleanly, and I made sure all links are still valid and working. I added a commit to update the copyright header dates.
Progress
Issue
Reviewers
Contributors
<djelinski@openjdk.org><hannesw@openjdk.org>Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/21326/head:pull/21326$ git checkout pull/21326Update a local copy of the PR:
$ git checkout pull/21326$ git pull https://git.openjdk.org/jdk.git pull/21326/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 21326View PR using the GUI difftool:
$ git pr show -t 21326Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/21326.diff
Webrev
Link to Webrev Comment