[crac] RFR: 8365241: [CRaC] Ignore new arguments when CRaCIgnoreRestoreIfUnavailable is true [v3]

Anton Kozlov akozlov at openjdk.org
Wed Aug 20 13:00:17 UTC 2025


On Mon, 11 Aug 2025 14:53:49 GMT, Timofei Pushkin <tpushkin at openjdk.org> wrote:

>> src/java.base/share/man/java.md line 1099:
>> 
>>> 1097:     instead of failing.
>>> 1098: 
>>> 1099:     When restoring with this option, you should specify a main class and its
>> 
>>> you **should** specify a main class
>> 
>> I guess we shall make this mandatory -> you **must** sepecify a main class? Do we have a test for the case when you run plain `java -XX:CRaCRestoreFrom=... -XX:+CRaCIgnoreRestoreIfUnavailable` and the image is not present?
>
> No, there is no such test currently.
> 
> You do not always have to specify a main class since if the image exists the main won't be used. Initially I wrote "you are expected to specify" and made it shorter into this version.

"Should" seems to fit. It won't be a violation of the interface, JDK will handle missing arguments and will and provide the help message, for example.

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

PR Review Comment: https://git.openjdk.org/crac/pull/261#discussion_r2288057068


More information about the crac-dev mailing list