CDN system on IPFS

Exciting of IPFS is designed to be used different ways typical one as web cdn system, practically saying its hard to be used as cdn functionality compare to the conventional cdn system.

The current cdn architecture usual two ( or three )layers, the central node/s and the edges, the central responsible of dns/ip load balance, flow control…the edge for real distribute content. So that the central node according to the client real ip to locate the closest edge to serve.
Unfortunately content on ipfs dont know which peers stored, till initial ipfs request may sure the content will be stored in the local storage (or surround peers ) – is it right? this will be extent time for the first access web page, no function of accelerate.

I have thought maybe ipfs cluster to handle this? designate some peers to specific domain?

Another issue involved with the dynamic web content, just like tweet-comment feature, user has published some comments on page, the database-dag (traditional mysql) whether immediately record and synchronize them or not?

I FOUND PUB/SUB maybe solve it ? orit db has use and confirm?

All thoughts & comments are welcome. thanks!

We already do CDN-like stuff with our public gateway system.

Geo-based DNS resolution points you to the closest gateway.

You can use IPFS Cluster to easily distribute content to all the peers serving your gateways too.

Finally, I’m not sure if IPFS bitswap includes any optimizations to fetch content from the closest peers (in terms of network latency), but otherwise it’s surely something that will arrive sooner or later.

2 Likes

An IPFS backed version oof https://addons.mozilla.org/en-US/firefox/addon/decentraleyes/ would be awesome

1 Like

yep! exactly what i have thought to use cluster & gateway do cdn-like thing. But that means need enough-efficiency gateway cause that all http requests and responses pass through the gateway, another point that if i want it server a large scale users , i need to deploy several clusters and gateways (as much as enough), that a file maybe several copies between clusters. no idea if original thought of ipfs.

And a puzzle in my mind that how to define the closest peer in ipfs ? Compare to tradition way use ip address ,ipfs has no real measurement of closest peer. is it right ?

how to use it with ipfs