cabal-club / cabal-desktop

Desktop client for Cabal, the p2p/decentralized/local-first chat platform.
https://cabal.chat
GNU Affero General Public License v3.0
850 stars 78 forks source link

feat: try to sync newly added cabals before listening to events #270

Closed nikolaiwarner closed 4 years ago

nikolaiwarner commented 4 years ago

By waiting for a few seconds before listening to cabal-client events, the db can have time to sync with peers without the client being overwhelmed with the flood of past events.

Here's a gif of an empty db loading the current public cabal:

2020-06-12 22 18 03

previously, loading the public cabal resulted in minutes of waiting and often required a few restarts or crashes to get through this initial sync.