mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 10:46:06 -04:00
Change device list replication to match new semantics.
Instead of sending down batches of user ID/host tuples, send down a row per entity (user ID or host).
This commit is contained in:
parent
f5caa1864e
commit
9ce4e344a8
4 changed files with 32 additions and 23 deletions
|
@ -94,9 +94,13 @@ PublicRoomsStreamRow = namedtuple(
|
|||
"network_id", # str, optional
|
||||
),
|
||||
)
|
||||
DeviceListsStreamRow = namedtuple(
|
||||
"DeviceListsStreamRow", ("user_id", "destination") # str # str
|
||||
)
|
||||
|
||||
|
||||
@attr.s
|
||||
class DeviceListsStreamRow:
|
||||
entity = attr.ib(type=str)
|
||||
|
||||
|
||||
ToDeviceStreamRow = namedtuple("ToDeviceStreamRow", ("entity",)) # str
|
||||
TagAccountDataStreamRow = namedtuple(
|
||||
"TagAccountDataStreamRow", ("user_id", "room_id", "data") # str # str # dict
|
||||
|
@ -363,7 +367,8 @@ class PublicRoomsStream(Stream):
|
|||
|
||||
|
||||
class DeviceListsStream(Stream):
|
||||
"""Someone added/changed/removed a device
|
||||
"""Either a user has updated their devices or a remote server needs to be
|
||||
told about a device update.
|
||||
"""
|
||||
|
||||
NAME = "device_lists"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue