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

Radim Vansa rvansa at openjdk.org
Mon Aug 11 14:41:33 UTC 2025


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

> Arguments are not passed to the restored process when `-XX:+CRaCIgnoreRestoreIfUnavailable` is set on restore. The check is performed on the side of the restoring VM since in the restored VM `CRaCIgnoreRestoreIfUnavailable` could have been set before the current restore.
> 
> Documentation for the new arguments feature and `CRaCIgnoreRestoreIfUnavailable` is also added, explaining this behavior.

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?

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

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


More information about the crac-dev mailing list