[crac] RFR: 8346386: [CRaC] Move CRaC’s Java code out of restricted packages

Timofei Pushkin duke at openjdk.org
Tue Dec 17 15:16:55 UTC 2024


On Tue, 17 Dec 2024 13:11:47 GMT, Radim Vansa <rvansa at openjdk.org> wrote:

>> To circumvent CRaC's limiting not-yet-standardized status:
>> 1. Moved CRaC interface from `javax.crac` in `java.base` to `jdk.crac` in a new `jdk.crac` module.
>> 2. Moved CRaC implementation from `jdk.crac` to `jdk.internal.crac.mirror`, both inside `java.base`. The whole CRaC implementation now resides in `jdk.internal.crac` which is exported (partially) only to the new `jdk.crac` module.
>
> src/java.base/share/classes/java/lang/System.java line 836:
> 
>> 834:      *
>> 835:      * @crac System properties can be updated on restore from a checkpoint.
>> 836:      * The application can {@link jdk.internal.crac.mirror.Context#register(jdk.internal.crac.mirror.Resource) register}
> 
> The docs should use the `jdk.crac` package; `jdk.internal.crac.mirror` should not be used from application. Could you check that the generated javadocs will then link correctly to the different module?

No, just swapping `jdk.internal.crac.mirror` with `jdk.crac` here does not work: javadoc complains that it cannot find the reference. I am not sure how to create inter-module links, there is `{@link java.logging/java.util.logging.Logger java.util.logging.Logger}` syntax in this file which successfully links to another module but using `jdk.crac/jdk.crac` does not work.

The current `jdk.internal.crac.mirror` also creates no link, probably because no docs are generated for this package. There is no error, just no hyperlink in the resulting HTML.

-------------

PR Review Comment: https://git.openjdk.org/crac/pull/164#discussion_r1888685738


More information about the crac-dev mailing list