Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Allow moving typing off master #7869

Merged
merged 11 commits into from
Jul 16, 2020
Merged

Allow moving typing off master #7869

merged 11 commits into from
Jul 16, 2020

Conversation

erikjohnston
Copy link
Member

A lot of this is various bits of rejigging, so probably worth looking at the commits.

Instead of always building EDUs on the writer process and using the
federation send queue to stream to the federation senders, we manage
sending of EDUs on the federation senders by looking at typing
replication stream.

This means we also have to move the timers for federation pokes to the
federation sending processes too.
@erikjohnston erikjohnston requested a review from a team July 16, 2020 11:33
erikjohnston and others added 2 commits July 16, 2020 13:52
Co-authored-by: Patrick Cloke <clokep@users.noreply.github.com>
erikjohnston and others added 2 commits July 16, 2020 13:57
Comment on lines +66 to +72
# map room IDs to serial numbers
self._room_serials = {}
# map room IDs to sets of users currently typing
self._room_typing = {}

self._member_typing_until = {} # clock time we expect to stop
self._member_last_federation_poke = {}

self.wheel_timer = WheelTimer(bucket_size=5000)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could just call self._reset here, but I suspect this code was all copy and pasted. 😄

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeeeeeeeeeeeeeees, though I'm not a huge fan of declaring attributes in not __init__ tbh :)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, that's true. I think type checkers don't like that. :)

Copy link
Member

@clokep clokep left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this looks good. 👍

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants