sc: support `delete_relationship` command
context
- when a user unsubscribes from a channel, signalboost deletes the
membership
table entry recording their relationship to the channel phone number - however, there is also a record of that relationship stored in the signal protocol store (namely: the identities and session records between a channel's account and the subscriber's account)
- this MR adds support for deleting those
behavior
WHEN a subscriber or admin sends GOOBYE
to a channel phone number
- THEN a psql session should not be able to discover any record of links between the subscriber's phone number and the channel's phone number
implementation sketch
- on receiving
SocketRequest.DeleteRelationship
(which should have anaccountId
and arelatedAccountId
(or something like that), signalc will query and delete all signal protocol records (identities, prekeys, and sessions) that haveaccountId
as their primary key and therelatedAccountId
as thename
field)
open question:
- what if a user unsubscribes then resubscribes?