2020-02-12 17:49:33
*https://github.com/snowblossomcoin/channels/compare/a605202538ff...2b6378cd3dec*
https://github.com/snowblossomcoin/channels/commit/2b6378cd3dec55033f017432c44216a9c0741847 - Assume ipv4 always works. Put seed node on 443.
GitHub
2020-02-12 17:58:53
*https://github.com/snowblossomcoin/channels/compare/2b6378cd3dec...321abeb18f7b*
https://github.com/snowblossomcoin/channels/commit/321abeb18f7baea01cf0fc1fc8d09679ebf7fe5b - Autoserve index.html from directories
GitHub
2020-02-12 21:53:33
wut?
Rotonen
2020-02-12 21:54:15
On which one?
Fireduck
2020-02-12 21:55:31
That entire WebServer.java is a dumpster fire.
Fireduck
2020-02-12 22:20:35
ipv4 assumption
Rotonen
2020-02-12 22:24:50
fair question. So the previous code would reach out to a thing I run in Google App Engine to get your effective IPv4 public address.
Fireduck
2020-02-12 22:25:13
You may or may not be able to accept connections on that address but, if you can reach the app engine site you certainly have working ipv4.
Fireduck
2020-02-12 22:25:38
However, if that site is down or blocked for some reason your node would assume IPv4 didn't work and would never try to use IPv4 to reach other nodes
Fireduck
2020-02-12 22:25:59
not very robust as that relies on you not kicking the bucket and/or something continuing to pay the bills
Rotonen
2020-02-12 22:26:03
So the logic now assumes you can reach other nodes by ipv4. If you can't, no major loss, other things will still be tried
Fireduck
2020-02-12 22:26:26
yeah, a blind cascade of trying things sounds better
Rotonen
2020-02-12 22:26:27
yeah, it is on my decentralization disclosure as something to fix
Fireduck
2020-02-12 22:27:02
I hope everything moves to ipv6. Then it is easy to get a list of local interfaces, any IPs in the group global are good things to use for peering (probably)
Fireduck
2020-02-12 22:27:48
how does that logic work if one is on an ipv6-only carrier? those are already a thing in china and africa
Rotonen
2020-02-12 22:28:13
There was another recent change where the blind trying things was added. https://github.com/snowblossomcoin/channels/commit/a605202538ffaa83db6abb29fa5966b2c3a21729#diff-8052364b95d35bba56209f83350c7818
Fireduck
2020-02-12 22:28:38
If you are on ipv6 only, you will try to connect via ipv4 (which won't work) and via ipv6 (which will).
Fireduck
2020-02-12 22:28:45
I like ipv6 so it has a higher weighting anyways
Fireduck
2020-02-12 22:29:06
should it wait for failures or just try everything at once?
Rotonen
2020-02-12 22:29:32
When you are trying to make a new connection to a peer, it puts everything that might work into a group and then picks one
Fireduck
2020-02-12 22:29:43
using some weighting
Fireduck
2020-02-12 22:30:21
eventually I could see saving some state and results from that
Fireduck
2020-02-12 22:30:34
but since connections tend to stay up after forming, this seems to work pretty well
Fireduck
2020-02-12 22:32:11
That is what the WeightedRandomSelector is about
Fireduck