Re: [RFC PATCH] Introduce git-hive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Aug 31, 2010 at 3:38 PM, Casey Dahlin <cdahlin@xxxxxxxxxx> wrote:

>        nguyen@host_b$ git config --add hive.uri http://myproject.org
>        nguyen@host_b$ git hive start host_a.com:21121
>
> So from host_b we specify host_a's address and listen port, and we join the
> network. From here on out anyone who also connects to host_a will get host_b's
> (randomly selected) listen port automatically and be able to connect to it as
> well.
>
> So now our two peers can see each other.

 ok - this only works if the two peers can see each other's ip
addresses.  i.e. if the two machines are either on a local subnet or
if the two machines are directly on the public internet.  ( or if
you've forced people to set up a firewall rule and/or UPnP rule, but
even then UPnP doesn't solve the entire problem - only one part of it)

 ... unless (and i haven't reviewed the code closely, i admit) you're
using the following protocol:

 * make tcp connection
 * send dedicated specific message "please tell me my public IP and port"
 * far end does sockaddr lookup of the incoming socket
 * far end returns IP and port as response to requestor

in this way, requestors can determine what the "apparent" IP address
is as far as having been NAT'd through half a ton of ISP layers
performing NAT, local routers performing NAT, laptops such as mine
doing NAT sharing of a 3G connection over a netgear router and so on.

so it entirely depends on the scope / scale you're thinking of.  if
you are aiming hive at "local subnets", it's pretty much perfect, and,
much as i hate to say it and you should not _remotely_ consider using
it because of the vast and horrific dependencies, i can understand why
you were considering avahi, because it is a good "local subnets"
solution.

however for "global networking" - for putting hive out onto the public
internet - there is one hell of a lot more involved, and all these
"filesharing" applications have solved near as damnit every single one
of the issues.

so, answering the question you were asking earlier: i believe that you
really do need to consider taking the closest c-based bittorrent
library/application apart, and use it as the basis for git-hive.  if
you don't, you will be here forever, reinventing everything that these
fileshare-app-writers have spent nearly a decade perfecting.

l.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]