mirror of
https://github.com/morluto/rea.git
synced 2026-11-20 05:32:44 +00:00
fix(hopper): name the unconfirmed shutdown step in retained cleanup (#10594)
* fix(hopper): name the unconfirmed shutdown step in retained cleanup When close_binary retains a Hopper document, the cleanup error lists the retained resources but not why shutdown went unconfirmed. On Linux CI, hopperClient.handshakeRecovery "recovers an application exit after the first valid handshake occurs during cleanup" fails intermittently. The vitest blob reports show only hopper-document and the runtime root retained with authenticated_application "readable". From those facts we cannot tell whether the shutdown request was not sent, failed, or was sent while the application was still observed as present. Record the shutdown request outcome (method, status, error tag and provider state, or why it was not sent) and the final exit observation of the authenticated application in the retained-document diagnostics. Exit observation now reports a positively observed Linux exit in progress (PF_EXITING before state Z) as "exiting", separate from "present". Neither confirms exit. The flaky test asserts the projected error, so a later failure prints these diagnostics in the CI log. Refs #10556 * fix(hopper): retain fallback shutdown diagnostics * test(hopper): retry cleanup after confirmed application exit
This commit is contained in:
1 parent
764203cf4a
commit
e939cd04fe
4 files changed
+175
-15
No files matched your search
@@ -94,6 +94,26 @@ describe("selected native process identity", () => {
|
||||
},
|
||||
);
|
||||
|
||||
it("reports an observed exit in progress without confirming exit", async () => {
|
||||
const exiting: ProcessOwnershipHost = {
|
||||
...host("start-1"),
|
||||
processIdentities: async () =>
|
||||
new Map([
|
||||
[
|
||||
42,
|
||||
{
|
||||
state: "readable",
|
||||
identity: "start-1",
|
||||
lifecycle: { state: "observed", lifecycle: "exiting" },
|
||||
},
|
||||
],
|
||||
]),
|
||||
};
|
||||
await expect(
|
||||
observeProcessStartIdentityExit(42, "start-1", exiting),
|
||||
).resolves.toBe("exiting");
|
||||
});
|
||||
|
||||
it("binds an omitted native PID to its directly observed run token", async () => {
|
||||
const omitted: ProcessOwnershipHost = {
|
||||
...host("start-1"),
|
||||
|
||||
Reference in new issue
Block a user