Commit Graph

30 Commits

Author SHA1 Message Date
Richard Ramos 975883407f refactor: improve mailserver batch handling 2023-05-02 07:27:57 -04:00
Richard Ramos 2ec97ee861 feat: use 24h batches for retrieving message history 2023-05-02 07:25:59 -04:00
Richard Ramos 323a6ce6dd test: processMailserverBatch 2023-04-30 10:04:04 -04:00
Richard Ramos ddfe16f56f fix: add cursors to store queries 2023-01-27 17:03:59 -04:00
Richard Ramos eb36eb3ee5 fix: cancel mailserver requests when stopping messenger 2023-01-25 11:15:12 -04:00
Richard Ramos b1960a6ca9 chore: increase mailserver timeout to 30s 2023-01-23 16:29:23 -04:00
Andrea Maria Piana 8593866862 Restart discovery when it fails
When discovery fails to be seeded with bootstrap/fallback nodes, it
never recovers.

This commit changes the behavior so that status-go retries fetching
bootnodes, and restarts discovery when that happens.
2022-12-14 20:54:48 +00:00
Richard Ramos eaced1c1e9 fix(store): generate signals per storenode request with custom requestIDs 2022-11-28 08:40:58 -04:00
Richard Ramos 4f5a25befa fix: limit store queries to 10 content topics 2022-11-09 21:38:05 +03:00
Pascal Precht 7032fc9dcc Introduce community history archive routine
This introduces logic needed to:

- Create WakuMessageArchives and and indices from store waku messages
- History archive torrent data to disk and create .torrent file from
  that
- Seed and unseed history archive torrents as necessary
- Starting/stopping the torrent client
- Enabling/disabling community history support for individual components
  and starting/stopping the routine intervals accordingly

This does not yet handle magnet links (#2568)

Closes #2567
2022-04-06 13:00:33 +02:00
Andrea Maria Piana d60a6713fe Enable mailserver cycle by default
This commit enables mailserver cycle logic by default and make a few
changes:

1) Nodes are graylisted instead of being blacklisted for a set amount of
   time. The reason is that if we blacklist, any cut in connectivity
   might result in long delays before reconnecting, especially on spotty
   connections.

2) Fixes an issue on the devp2p server, whereby the node would not
   connect to one of the static nodes since all the connection slots
   where filled. The fix is a bit inelegant, it always connects to
   static nodes, ignoring maxpeers, but it's tricky to get it to work
   since the code is clearly not written to select a specific node.

3) Adds support to pinned mailservers

4) Add retries to mailservers requests. It uses a closure for now, I
   think we should eventually have a channel etc, but I'd leave that for
   later.
2022-03-19 08:56:22 +00:00
Roman Volosovskyi 62a0439234
[#12783] fix index out of range when there are no filters 2022-02-02 16:52:50 +02:00
Roman Volosovskyi c0c90947ab
[#12783] Improve order of mailserver requests 2022-02-02 09:38:30 +02:00
Richard Ramos 6dcc059031
chore: increase mailserver request timeout (#2497) 2022-01-26 11:20:27 -04:00
Richard Ramos ebd4511d24
fix: remove mailserver topic when deactivating a chat (#2460)
This fixes an issue where re-joining a chat does not load the messages again from the mailserver
2021-12-09 17:55:00 -04:00
Andrea Maria Piana f60cf5cd47 Wait for p2p messages to be processed 2021-12-01 12:58:46 +00:00
Anthony Laibe 25e1c64ef5
fix: iterate through message with batch topics (#2444)
When iterating, reuse the list of topics rather
than all topics
2021-11-26 12:59:53 +01:00
Andrea Maria Piana 6724cf4c75 Block contact endpoint 2021-11-15 18:53:35 +00:00
Andrea Maria Piana ca6246d5f2 Set last backup 2021-11-15 18:53:35 +00:00
Roman Volosovskyi 53bbfb3f08
Allow sending messages offline 2021-11-11 19:12:31 +02:00
Richard Ramos 7440c184c0
feat: add batch information and request ID in history requests (#2397) 2021-11-09 16:16:19 -05:00
Andrea Maria Piana 2d13fa1e25 Add logging of message-id 2021-11-01 11:53:08 +00:00
Richard Ramos 3b05d379bd
feat: add signals that are emitted before/after history messages are requested (#2378)
* fix: sqlite variable limit

* feat: add signal for history messages
2021-09-28 14:41:35 -04:00
Andrea Maria Piana c35ceff06e Set timeout on mailserver requests 2021-08-03 11:16:37 +02:00
RichΛrd bfdc000bbc
go-waku: RequestAllHistoricMessages (#2258)
* feat: update wakuv2 store

* check online using waku version for now

* fix peerId and from/to multiplier

* fix: lint

* fix: handle waku2 cursors

* fix: code review

* fix: code review 2

* update go-waku version

* update vendor folder
2021-07-21 15:02:50 -04:00
Andrea Maria Piana 60de443e89 address feedback 2021-06-01 12:59:52 +02:00
Andrea Maria Piana af1e47c258 Fix group chat filters 2021-06-01 12:59:52 +02:00
Andrea Maria Piana 3a61c3bae9 Allow setting mailserver sync value
This commit adds a setting for mailserver, that allows the client to
specify the syncing period.
Also fixes a minor issue with deletion of public chats.
2021-06-01 12:59:52 +02:00
Andrea Maria Piana d50fee6bb2 Handle connection state 2021-05-21 07:22:58 +02:00
Andrea Maria Piana cf6ef3171a Add mailserver logic 2021-05-21 07:22:58 +02:00