0

I am about to develop a distributed system. The system, among all functionalities, needs to allocate some resources (large resources that can be fragmented in smaller blocks). In order to do that, I want to use the Chord/Pastry P2P approach (stations on a logic ring-net). Pastry has a very interesting approach for resource allocation: when a user station needs to send something, the hash of the station guid is used to find the key in the dht, so something like this is considered:

User Station -> GUID (hash on user station ip) -> HASH -> I obtain a value called X -> Use this hash and find in the Pastry ring-net the station having that same GUID (hash on Pastry node public key) value is located (or the immediate predecessor) -> put data there.

Well, this means that, ideally, every user always locates its own data in the same Patry station (Pastry node). Well, the protocol also mirrors data on neighbours so a user can find its data in few nodes.

Is this a good approach? Are there any possible side effects on proceeding as before?

4

1 回答 1

0

Pastry-P2P 类解决方案是理论模型。因此,您应该将它们视为它们的本质,一种抽象。

这些模型没有考虑对等点的实际搜索以及尝试建立与远程对等点的连接时遇到的技术困难(例如,NAT 穿越和防火墙问题)。对等点也可能已关闭。

连接到下一个对等点的成本并不总是 1。它可能会更多。要回答您的问题,您不能只依赖所选模型。

话虽如此,如果哈希结果是均匀分布的,那么对等点之间的性能变化就会很小,除非它们在 NAT、代理或防火墙后面特别难以到达。

于 2011-09-12T17:46:55.257 回答