[Seeks-users] DHT code evolution (repost)
Status: Beta
Brought to you by:
beniz
|
From: Loic D. <lo...@da...> - 2010-12-22 09:05:28
|
Hi, I completed a rewrite of the stabilization of the successor list of the seeks DHT today, with the associated tests. It is available at http://seeks.dachary.org/seeks.git In my opinion the changes that shoud be done to estabish a sound base for the DHT are the following: * replacing the stabilization loop with libevent * reducing to a single thread instead of two (with libevent) * use UDT instead of UDP * cache DNS resolution * use a pool of remote nodes modeling their accessibity accross virtual nodes * use Location instead of DHTKey + NetAddress * replace the protobuf wrappers with a hierarchy of derived classes Each of them taken individually are relatively easy to agree on. All together they look like more work than necessary to get started. It would certainly be possible to have a working DHT without doing this ground work. But I believe it would seriously jeopardize our ability to build on safe grounds. In the past weeks I wrote tests and extensively explored the existing code. I don't think I missed an area that would contradict the diagnostic above. I adapted and refactored locally to the best of my abilities. But I believe it is time, using our combined experiences, to restructure the code to match all of the above constraints at once. One could argue that it would be a waste of time to carefull restructure and that it is more important to get something working quickly. But if that was the case, chosing a ready made solution such as maidsafe would be a lot quicker. The main reason to implement a DHT is to make it an integral part of seeks instead of a tool box imported from a third party. Cheers |