vyzo
a1ebc4d852
reduce relay find peer and connect timeout to 30s
6 years ago
vyzo
ffd4981247
increase autorelay discovery limit to 1k
6 years ago
vyzo
1e48e15da7
respect NoDial option in routed host
6 years ago
vyzo
a4776e6174
fix panic in observed address activation check
The activated check cleans up, which leads to panics with concurrent reads.
This moves the seenBy set clean up into gc, where it belongs
6 years ago
vyzo
efdc140264
raise activation channel capacity to 16
6 years ago
vyzo
fe7ba05e38
delete empty address sets on observed address set gc
6 years ago
vyzo
17001b24dd
use a read/write lock for observed address set
6 years ago
vyzo
f4af8d493d
fix identify tests
6 years ago
vyzo
9b8192b7d2
initialize ttl in ObservedAddrSet
6 years ago
vyzo
b8a152f593
use a background worker for updating/gcing the observed address set
6 years ago
vyzo
e76c8a9c38
don't eagerly update the observed address set in Addrs
allocates and eats a lot of cpu time under the lock;
let a background worker gc periodically.
6 years ago
Steven Allen
316f0867f6
identify: avoid parsing/printing multiaddrs
6 years ago
Steven Allen
aebe405680
test: disable TestAddAddrsProfile when the race detector is enabled
6 years ago
whyrusleeping
a7eb2efe4b
move things outside of the lock in obsaddr
6 years ago
Steven Allen
bcbf7a59c1
identify: only record observed addresses that match an address we're announcing
This is should prevent us from, e.g., announcing relay addresses _just_ because
a peer tells us we're reachable through a relay.
6 years ago
Steven Allen
7093262620
relay: update documentation
6 years ago
vyzo
45df977d57
bump relay record limit to 50
6 years ago
Steven Allen
5b665643c7
relay: only stop advertising relay addresses if we fully disconnect
6 years ago
Steven Allen
80ada8a7d6
relay: no more wrapping
We don't need the host wrappers, we can just replace the filter AddrsFactory.
Also, always filter out relay addresses.
6 years ago
Steven Allen
544c412193
identify: only store _reported_ multiaddrs
We still tell the remote host about the observed addr but we don't store it.
That way, we give them a chance to decide if they want to actually use and
advertise it.
Ideally, we'd distinguish between local information and signed routing
information but we don't do that yet.
This should reduce the address explosion issue where peers learn about
multiple (bad) observed addresses for the same peer. It should also give peers
more control over how they can be dialed.
6 years ago
vyzo
62531f9a10
reduce autorelay boot delay to 20s
6 years ago
vyzo
bace7d4ceb
autorelay: correctly handle private->public transition
6 years ago
vyzo
c3b5ece119
reduce autorelay discovery timeout to 30s
6 years ago
vyzo
e2412502a6
reduce autorelay boot delay to 30s
6 years ago
Steven Allen
16a60f9751
reduce nat error level
6 years ago
Lars Gierth
7741442478
relay: simplify declaration of multiaddr var
6 years ago
lnykww
5da711dc6c
Fix UDP listen on a Unspecified Address and Dial from the Unspecified Address
LocalMultiaddr May return the Unspecified Address, if so, we need to
check if we listen on the Unspecified address and they were equal.
6 years ago
Leonhard Markert
2a7478131a
Fix typos in p2p/net/README.md
"Requet" -> "Request", "tls" -> "TLS"
6 years ago
Steven Allen
5c51323aa2
mock: increase tolerance for latency tests
These were exceeding their tolerances when run under the race detector on CI.
6 years ago
Steven Allen
5b643cde2d
mock: reduce peer count in FuzzManyPeers when the race detector is enabled
6 years ago
Steven Allen
e96aefc3b3
autorelay: disable consistantly failing auto-relay test
6 years ago
Steven Allen
58f40b9d11
mocknet: fix data race
6 years ago
Steven Allen
8c8f08e36f
natmgr: rename refresh to sync
6 years ago
Steven Allen
3617750071
better nat mapping
1. Update to work with https://github.com/libp2p/go-libp2p-nat/pull/14 .
2. Avoid observed addrs when our NAT tells us about external addrs.
3. Ignore bad addrs reported by our NAT. Substitute with observed addrs.
4. Fix https://github.com/libp2p/go-libp2p/issues/428 .
6 years ago
Jakub Sztandera
533d9866c6
gx publish 6.0.34
6 years ago
Matt Joiner
3b8d83ffdc
Resolve addrs with P2P instead of IPFS ( #539 )
6 years ago
iulianpascalau
b8e47c5dea
mock package:
- changed GetStreams function from mock_conn.go to call allStreams which has the same functionality but is concurrent safe
- changed protocol field from mock_stream to be concurrent safe. Taken the implementation from swarm_stream.go
6 years ago
vyzo
7fa37513fd
increase initial relay advertisement delay to 30s
6 years ago
vyzo
3a993345d0
use PeerRouting in autorelay to find relay peer addresses
6 years ago
vyzo
c5f50f9c2d
don't advertise the raw public address in autorelay
6 years ago
Steven Allen
758b516603
mock: export ratelimiter as RateLimiter
Technically a breaking change because I changed the constructor casing but
nobody's using this outside of libp2p (yet), mostly because the type hasn't been
exported.
6 years ago
vyzo
5d0a6e23ce
use select for initial advertisement delay
6 years ago
vyzo
a1b5b9ed53
explicit option to enable autorelay
6 years ago
Abhishek Upperwal
36a2645306
removing redundant if condition
6 years ago
Abhishek Upperwal
3ae2d75e46
added comments for clarity
6 years ago
Abhishek Upperwal
88d98287ff
suppressing error msg for NoSecurity option
6 years ago
vyzo
31eb77d446
add delay in initial relay advertisement to allow the dht time to bootstrap
6 years ago
Steven Allen
79ba610d21
mocknet: create a connection on NewStream if we need one
That's what the Swarm does and that's what the function's documentation says it
does.
6 years ago
Steven Allen
a8e25bf270
mocknet: refuse to connect to self
The swarm does this as well and most of our services will fail if we don't have
this.
6 years ago
Steven Allen
00ba6a165a
deflake identify test
This was probably failing (rarely) due to the fact that we're shrinking the
timeout asynchronously (I think?).
6 years ago