Preserves ETS tables across Roux.Database.TableOwner crashes.
When TableOwner dies, ETS automatically transfers all heir-protected tables
to this process via ETS-TRANSFER messages. The new TableOwner calls
reclaim/1 in its init/1 to get them back. During normal operation this
process is idle.
Started before TableOwner under a :rest_for_one supervisor. Its PID is
published via :persistent_term so TableOwner can find it without passing
PIDs through the supervisor spec.
Summary
Functions
Returns a specification to start this module under a supervisor.
Reclaims all tables held by the heir process.
Reads the heir PID from persistent_term for the given supervisor.
Types
Functions
Returns a specification to start this module under a supervisor.
See Supervisor.
Reclaims all tables held by the heir process.
Called by a freshly started TableOwner. The heir gives away each table to
the caller and returns the table map. Returns {:ok, %{}} when no tables
are held (fresh start).
Reads the heir PID from persistent_term for the given supervisor.