我想使用P2P构建一个分散的,类似reddit的系统.我应该基于哪些现有的p2p库? [英] I want to build a decentralized, reddit-like system using P2P. What existing p2p library should I base it on?

查看:71
本文介绍了我想使用P2P构建一个分散的,类似reddit的系统.我应该基于哪些现有的p2p库?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用P2P构建一个分散的,类似Reddit的系统.基本上,我想保留reddit的基本功能,但要使其分散化,以使其更强大并不受审查.这也将使人们能够开发不同的客户,以匹配他们想要浏览它的方式.

I want to build a decentralized, reddit-like system using P2P. Basically, I want to retain the basic capabilities of reddit, but make it decentralized, to make it more robust and immune to censorship. This will also allow people to develop different clients to match the way they want to browse it.

您能推荐好的p2p库作为我的工作基础吗?它们应该是开源的,跨平台的,健壮的且易于使用的.我不太在乎语言,我可以适应.

Could you recommend good p2p libraries to base my work on? They should be open-source, cross-platform, robust and easy to use. I don't care much about the language, I can adapt.

推荐答案

免责声明:警告,在这里自我宣传

Disclaimer: warning, self-promotion here !!!

您是否考虑过JXTA的最新版本?这可能足以满足您的需求.否则,我们正在开发一个名为 Chaupal 的新P2P框架,但该框架尚未投入使用.

Have you considered JXTA's latest release? It is probably sufficient for what you want to do. Else, we are working on a new P2P framework called Chaupal, but it is not operational yet.

编辑

还有我所说的快速而又简单的UDP解决方案(毕竟它不是很脏,我应该将其称为最小).

There is also what I call the quick-and-dirty UDP solution (which is not so dirty after all, I should call it minimal).

  1. 只需用公共地址实现一台服务器,然后开始监听UPD.
  2. 位于NAT后面的对等方联系服务器,服务器可以从接收到的数据报中读取其私有IP地址如何转换为公共IP地址.
  3. 您将该信息发送回对等方,该对等方可以将其转发给其他对等方.服务器还可以帮助在同级之间交换此信息.
  4. 然后,对等方可以通过将数据报发送到这些转换的地址来直接(一对一)进行通信.

简单,易于实现,但不涵盖丢失的数据报,重播,乱序等...(即TCP在IP堆栈级别为您解决的典型问题).

Simple, easy to implement, but does not cover for lost datagrams, replays, out-of-order etc... (i.e., the typical stuff that TCP solves for you at the IP stack level).

这篇关于我想使用P2P构建一个分散的,类似reddit的系统.我应该基于哪些现有的p2p库?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆