Simon-Pierre Vivier
d389d96789
feat: rendezvous refactor ( #1183 )
...
Hello!
This PR aim to refactor rendezvous code so that it is easier to impl.
Waku rdv strategy. The hardcoded min and max TTL were out of range with
what we needed and specifying which peers to interact with is also
needed since Waku deals with peers on multiple separate shards.
I tried to keep the changes to a minimum, specifically I did not change
the name of any public procs which result in less than descriptive names
in some cases. I also wanted to return results instead of raising
exceptions but didn't. Would it be acceptable to do so?
Please advise on best practices, thank you.
---------
Co-authored-by: Ludovic Chenut <ludovic@status.im>
2024-09-25 09:11:57 +00:00
Álex
48846d69cb
chore(logs): remove duplicate msg key ( #1180 )
...
* Remove `msg` parameter key in logs.
closes: https://github.com/vacp2p/nim-libp2p/issues/1176
2024-08-14 17:19:54 +02:00
gabrielmer
a60f0c5532
feat: adding onValidated observer ( #1128 )
...
### Description
Adding an `onValidated` observer which will run every time a message is
received and validated. This comes from the necessity of precisely track
message deliveries and network activity.
`onRecv` observers run before any check is performed on the received
message, which means that it runs every time a duplicate or invalid
message arrives, which is inefficient and inaccurate for our purpose of
tracking only received, unique and valid messages. Therefore, adding
this extra option of running an observer for every message after all
validation checks pass.
2024-08-01 18:50:13 +03:00
diegomrsantos
78f0855419
feat: add maxSize to TimedCache ( #1132 )
2024-07-01 22:00:51 +02:00
diegomrsantos
2195313dba
feat: iDontWant is sent only for gossipsub 1.2 or higher ( #1135 )
2024-06-25 19:32:08 +02:00
diegomrsantos
7498258f7c
fix(gossipsub): pubsubpeer is created with wrong gossipsub version ( #1116 )
2024-06-13 12:25:48 +02:00
diegomrsantos
96bfefc928
feat(gossipsub): support version 1.2.0 ( #1106 )
2024-06-12 15:46:47 +02:00
diegomrsantos
dc83a1e9b6
chore(formatting): format the whole codebase using nph 0.5.1 ( #1118 )
2024-06-11 17:18:06 +02:00
kaiserd
d6feb1bbc2
chore(peer-score): enhance score trace logs cont' ( #1108 )
2024-06-03 14:57:20 +02:00
Ivan FB
3f5b5cee75
chore(peer-scoring): enhance score trace logs ( #1107 )
2024-06-03 12:25:47 +02:00
Jacek Sieka
8a4e8a00a2
Send IDONTWANT before validating message ( #1103 )
2024-06-03 10:34:05 +02:00
diegomrsantos
2fa2c4425f
fix(yamux): set EoF when remote peer half closes the stream in yamux ( #1086 )
2024-05-24 14:11:27 +02:00
kaiserd
0911cb20f4
chore(gossipsub): cleanups ( #1096 )
2024-05-15 18:57:15 +02:00
Jacek Sieka
21cbe3a91a
chore: cleanups ( #1092 )
...
* remove cruft
* remove redundant error handling (reduces warnings)
* remove redundant copying
2024-05-08 14:33:26 +02:00
diegomrsantos
88e233db81
fix: Asynchronous task [sendMsgSlow()] was cancelled [FutureDefect] ( #1094 )
2024-05-07 15:44:14 +02:00
Jacek Sieka
84659af45b
avoid latency/copy when sending low-priority messages to fast peers ( #1060 )
2024-05-02 12:26:16 +02:00
Jacek Sieka
aef44ed1ce
salt `idontwant` ( #1090 )
2024-05-02 12:18:55 +02:00
Jacek Sieka
02c96fc003
Improve memory efficiency of seen cache ( #1073 )
2024-05-01 18:38:24 +02:00
diegomrsantos
89cad5a3ba
fix: remove explicit param from GossipSubParams constructor ( #1080 )
2024-04-09 20:14:59 +02:00
Etan Kissling
03f67d3db5
add support for setting protocol handlers with `{.raises.}` annotation ( #1064 )
2024-03-28 09:42:31 +01:00
diegomrsantos
bb97a9de79
improvement: create a new gossipsub constructor ( #1078 )
2024-03-27 11:54:15 +01:00
diegomrsantos
1a707e1264
feat: add max number of elements to non-prio queue ( #1077 )
2024-03-25 22:00:11 +01:00
Álex Cabeza Romero
458b0885dd
fix(issue-1052): Single topic for RPC Message ( #1061 )
2024-03-25 12:06:34 +01:00
Jacek Sieka
a2027003cd
Avoid unnecessary rate limit message copy ( #1067 )
2024-03-21 13:11:40 +00:00
Jacek Sieka
d1e51beb7f
Remove `secio` ( #1072 )
2024-03-20 14:53:56 +01:00
Jacek Sieka
467b5b4f0c
avoid cancelling send future ( #1075 )
2024-03-20 10:54:32 +00:00
Etan Kissling
48a3ac06ff
`{.async: (raises).}` for `MultistreamSelect` ( #1066 )
2024-03-12 21:05:53 +01:00
Etan Kissling
49a92e5641
avoid pointless exception raising in `dcutr/server` ( #1063 )
2024-03-12 18:29:01 +01:00
Etan Kissling
08a48faf41
`{.async: (raises).}` annotations for `protocols/secure` ( #1059 )
2024-03-07 11:22:22 +00:00
Etan Kissling
61b299e411
`{.async: (raises).}` for `relay/utils.nim` ( #1058 )
2024-03-07 10:45:25 +01:00
Jacek Sieka
ae13a0d583
Send priority with queue fix ( #1051 )
...
Co-authored-by: Diego <diego@status.im>
2024-03-05 15:05:21 +00:00
Etan Kissling
28609597d1
add `{.async: (raises).}` to `libp2p/stream` modules ( #1050 )
...
Co-authored-by: Dmitriy Ryajov <dryajov@gmail.com>
Co-authored-by: Jacek Sieka <jacek@status.im>
2024-03-05 07:06:27 +00:00
Etan Kissling
9059a8aced
use `race` instead of `or` to avoid lockup ( #1042 )
2024-03-04 00:06:32 +01:00
Etan Kissling
1609fd7197
change `SecioError` and `NoiseError` to descendants of `LPStreamError` ( #1047 )
2024-03-04 00:04:25 +01:00
Etan Kissling
6c873481ac
move `allFutureThrowing` helper to tests ( #1037 )
...
Co-authored-by: Jacek Sieka <jacek@status.im>
2024-03-01 18:06:26 +01:00
Diego
c5e4f8e12d
Revert "feat: message prioritization with immediate peer-published dispatch and queuing for other msgs ( #1015 )"
...
This reverts commit fe4ff79885
.
2024-02-19 13:47:37 +01:00
diegomrsantos
fe4ff79885
feat: message prioritization with immediate peer-published dispatch and queuing for other msgs ( #1015 )
2024-02-16 10:54:16 +01:00
diegomrsantos
5594bcb33e
fix: more metrics issues when libp2p_expensive_metrics is enabled ( #1016 )
2024-01-30 16:55:55 +01:00
diegomrsantos
d46bcdb6ac
fix: compilation issue when `libp2p_expensive_metrics` is enabled. ( #1014 )
2024-01-29 11:31:11 +01:00
Etan Kissling
c6566707fa
include connection info when logging identify message ( #991 )
2023-12-05 18:44:16 +01:00
Jacek Sieka
2ede0fa40c
remove redundant gcsafe annotations ( #999 )
2023-12-05 08:05:32 +01:00
diegomrsantos
deb72c8580
fix(dcutr): update the DCUtR initiator transport direction to Inbound ( #994 )
2023-11-29 17:38:47 +01:00
diegomrsantos
ce0685c272
fix(identify): do not add p2p and relayed addrs to observed addr manager ( #990 )
2023-11-21 18:24:35 +01:00
diegomrsantos
1f4b090227
fix(yamux): doesn't work in a Relayv2 connection ( #979 )
...
Co-authored-by: Ludovic Chenut <ludovic@status.im>
2023-11-21 16:03:29 +01:00
diegomrsantos
fb05f5ae22
fix(dcutr): handle tcp/p2p addresses ( #989 )
2023-11-20 17:06:17 +01:00
diegomrsantos
4b3bc4f819
Make ObservedAddrManager injectable ( #970 )
2023-11-20 11:06:02 +01:00
diegomrsantos
6791f5e7bb
fix(dcutr): make the dcutr client inbound and the server outbound ( #983 )
2023-11-17 10:46:35 +01:00
diegomrsantos
ebef85c9d7
Rate limit fixes ( #965 )
2023-11-09 14:20:28 +01:00
diegomrsantos
3fc1236659
Revert "Prevent concurrent IWANT of the same message ( #943 )" ( #977 )
2023-11-03 15:24:27 +01:00
diegomrsantos
459f6851e7
Add a flag if a peer should be disconnected when above rate limit ( #954 )
2023-10-05 14:51:27 +02:00