[crac] RFR: Fix ordering of invocation on Resources [v3]
Radim Vansa
duke at openjdk.org
Wed May 3 11:06:44 UTC 2023
On Fri, 28 Apr 2023 11:48:16 GMT, Anton Kozlov <akozlov at openjdk.org> wrote:
>> Radim Vansa has updated the pull request incrementally with two additional commits since the last revision:
>>
>> - More fine-grained synchronization
>> - Rework context ordering (round 2)
>>
>> * call afterRestore even if beforeCheckpoint throws
>> * registering resource in previous/running context does not trigger exception immediatelly
>> ** instead this will be one of the recorded exceptions and the resource has a chance to fire next time
>> * we don't guarantee threads not deadlocking when trying to register a resource, though
>
> src/java.base/share/classes/jdk/crac/impl/AbstractContextImpl.java line 42:
>
>> 40: for (Throwable t : suppressed) {
>> 41: Core.recordException(t);
>> 42: }
>
> Unwrap Checkpoint/RestoreException only?
This is how it's actually used; can't use union type in Java. I'll add an assertion to make this clear...
-------------
PR Review Comment: https://git.openjdk.org/crac/pull/60#discussion_r1183542544
More information about the crac-dev
mailing list