-
-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Published name lifetime inconsistent with DHT and default values #7534
Comments
Thank you for submitting your first issue to this repository! A maintainer will be here shortly to triage and review.
Finally, remember to use https://discuss.ipfs.io if you just need general support. |
@BubuAnabelas if you have documentation suggestions that could be reasonable. However, it's worth pointing out that record attributes (e.g. lifetime) are part of the signed IPNS record which could be propagated using many different systems of which the public IPFS kademlia network is only one. For example, IPNS over PubSub does not delete records every 36h. |
I wasn't aware that IPNS over PubSub was already working and I'm not familiar with its internal features, please point me out to its docs or code. Also maybe changing the labels of this issue from king/bug to king/enhancement and topic/docs-ipfs? |
spec: https://github.com/ipfs/specs/blob/master/naming/pubsub.md
Why do you feel that the particulars of the router here should be exposed to the user? In particular, it's worth noting that if you set the lifetime of your record to be 5 years and published it to the DHT it's actually possible that the record could still be in the DHT and valid 5 years from now since if you turn off your machine an interested third party could manually republish the record in the DHT for you. The 36 hours business is just about how long a DHT server node is willing to keep data around for without it being reminded, but it's a pretty low level piece of information. Note, you may need to republish more frequently then this based on the churn rate of the network (i.e. the frequency of DHT servers going online and offline) and go-ipfs will automatically republish IPNS records as determined by your config file (https://github.com/ipfs/go-ipfs/blob/master/docs/config.md#ipnsrepublishperiod). |
My thought are specially considering the case in which a user doesn't want to keep go-ipfs running to automatically republish (or doesn't know it might be necessary) and I feel it can be a little misleading to publish with a long lifetime given that the actual lifetime of the record depends on many different factors. Lets assume Alice (a non-technical user) wants to publish a website so she uses IPNS, she just runs I think this case is similar to what #590 was for pinning. |
mildly related: #8586 (adding an explicit IPNS reprovider duration would make lifetime more useful, because other peers could keep republishing a valid signed record created by other peer) |
Version information:
go-ipfs version: 0.6.0
Repo version: 10
System version: amd64/windows
Golang version: go1.14.4
Description:
I was making some changes to ipfs-watch-and-publish and noticed that
ipfs name publish --lifetime
accepts huge arguments (i.e. 1 year = 8760h) and still publish it successfuly. The default record lifetime is 24 hours and libp2p-kad-dht's default max record age is 36 hours so, I guess even if I pass "48h" as the lifetime parameter it would expire after 36 hours anyway.It's kinda confusing, given that the DHT options are different across the nodes, maybe it could be useful to check that the lifetime parameter is lower than the local DHT's max record.
This can be related to libp2p/go-libp2p-kad-dht#397
The text was updated successfully, but these errors were encountered: