HomePhabricator
Diffusion Comm 9202ff4d71e4

[lib] Initiate a keyserver session recovery when keyserver socket sends…

Description

[lib] Initiate a keyserver session recovery when keyserver socket sends not_logged_in

Summary:
I think it makes more sense to use a session recovery here, since it has the ability to automatically log the user in, which would presumably address the not_logged_in issue.

If the session recovery fails, it will result in the user's session being invalidated, and the user being logged out. This matches the current behavior of setConnectionIssueActionType.

NOTE: This diff removes the only kind of ConnectionIssue. It's not ready yet, but in a later diff I will introduce a new kind of ConnectionIssue that we will use for when session recovery fails for a non-authoritative keyserver, instead of calling setNewSession. At that point I'll clean up the hacks in keyserver-reducer.test.js.

Depends on D11217

Test Plan: Part 4.2 of this test plan: https://gist.github.com/Ashoat/75ab690d5c53cdd68a51b02e03e27c58

Reviewers: inka, tomek

Reviewed By: tomek

Differential Revision: https://phab.comm.dev/D11218