Skip to content
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

Use W3name web sockets for updates #651

Open
juliangruber opened this issue Dec 17, 2024 · 2 comments
Open

Use W3name web sockets for updates #651

juliangruber opened this issue Dec 17, 2024 · 2 comments
Labels
good first issue Good for newcomers

Comments

@juliangruber
Copy link
Member

juliangruber commented Dec 17, 2024

https://github.com/storacha/w3name/tree/main/packages/api#get-namekeywatch---receive-updates-via-websocket-when-new-values-are-published-to-a-name

Instead of polling Name.resolve() twice every 10 minutes every instance, only read it on process start (or test if the WebSocked emits the current value on connect), and then use the WebSocket API for updates.

This should both be faster for Station and cheaper for W3Name

Caveat: This might create too many open connections on W3Name, so test carefully.

@bajtos
Copy link
Member

bajtos commented Dec 17, 2024

It makes me wonder - since IPNS was designed for peer-to-peer world, should we look into ways how to share the latest IPNS->IPFS CID mapping via p2p mechanisms like libp2p gossipsub? (Using w3name as a fallback or a way to boostrap the p2p state.)

@juliangruber
Copy link
Member Author

The request load is currently not a problem for w3name, so this would be low priority. I agree that a more p2p solution would be better

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants