[zeromq-dev] An interesting use-case for EdgeNet : Asynchronous IRC?

Lindley French lindleyf at gmail.com
Mon Jan 6 22:12:28 CET 2014


Now that I've read Chapter 8 completely, I'm quite certain I could help get
zyre working on Android once I get hold of a phone. For one thing, I've
already created a very similar system for Android, so many of the same
lessons should apply. It was a bit bizarre how similar my solution to peer
messaging was to Zyre, actually----I found myself nodding many times
throughout that chapter. UDP beacons for discovery, pooled TCP connections
for peer messaging, the need for a HELLO message of sorts (although in my
case, it went out with every new TCP connection, so port reuse wasn't an
issue). I also sympathize entirely with the problems of setting up 30-phone
simulations, at least until our python codebase matured to automate the
process and we created a tool to issue ADB commands to all the phones in
parallel.

This tells me that we're both probably on the right track.

The main differences were:
1) Mine was written in almost pure Java (one or two Android-specific things
made it in).
2) I had to manage the TCP connections myself since I didn't use 0MQ. Also,
messages flowed both ways across a single connection between peers rather
than using multiple connections as in the Harmony pattern.
3) I put a lot of effort into giving senders a confirmation that their
message had made it, or letting them know I wasn't able to confirm it,
using a java Future and messaging ACKs.
4) I had a capability to supplement the beacon broadcasts with additional
beacon unicasts to specified addresses. This turned out to be all that was
necessary to create geographically distant "peers" under controlled
circumstances. (I didn't address discovery of what addresses to unicast to.)
5) The system was created from the start to be edge-oriented rather than
node-oriented. That is, a peer was defined both by the destination and the
interface used to reach it.
6) I never attempted group messaging, although I was aware it was a
desirable goal.



On Wed, Jan 1, 2014 at 4:37 PM, Pieter Hintjens <ph at imatix.com> wrote:

> Lindley, would you be able to help get Zyre et all working on Android?
>
> On Wed, Jan 1, 2014 at 8:44 PM, Lindley French <lindleyf at gmail.com> wrote:
> > Oh---and some network functionality shuts down on Android when the
> device is
> > inactive if you don't take the appropriate lock. This is a critical
> > consideration when designing edge networking services.
> >
> > On Jan 1, 2014, at 1:17 PM, Lindley French <lindleyf at gmail.com> wrote:
> >
> > On Android at least, if you have any trouble with UDP broadcast or
> > multicast, you should trying using the IPv6 all-hosts address. Android's
> > built-in filtering doesn't seem to affect IPv6 the same way as IPv4.
> >
> >
> > On Wed, Jan 1, 2014 at 12:10 AM, Sean Robertson <sprobertson at gmail.com>
> > wrote:
> >>
> >> I have something like this in the works, in the form of an iOS
> application
> >> that I hope to soon port to Android. It doesn't properly use Zyre but
> rather
> >> my own haphazard  reimplementation, due to some silliness with Apple's
> UDP
> >> broadcast (https://github.com/zeromq/czmq/issues/297). The UI works
> decently
> >> though. I'll send the code to this list later this week.
> >>
> >> On Dec 31, 2013 6:38 PM, "Lindley French" <lindleyf at gmail.com> wrote:
> >>>
> >>> Asych twitter is a good idea and will work well. I've seen it done.
> >>> Another fun application is async push to talk.
> >>>
> >>> On Dec 31, 2013, at 9:32 PM, crocket <crockabiscuit at gmail.com> wrote:
> >>>
> >>> May asynchronous twitter be more appropriate for my idea?
> >>> Asynchronous twitter, asynchronous IRC, whatever.
> >>>
> >>>
> >>> On Wed, Jan 1, 2014 at 11:19 AM, crocket <crockabiscuit at gmail.com>
> wrote:
> >>>>
> >>>> With asynchronous IRC software, you can choose your nickname and a
> >>>> topic.
> >>>> You send messages that belong to a topic.
> >>>> People who subscribed to that topic receive your message.
> >>>> Or they might choose to receive messages from every topic.
> >>>>
> >>>> This becomes very interesting when population density goes up very
> high
> >>>> in a small area.
> >>>> Imagine that you went to comiket. Wikipedia says "Comiket (コミケット
> >>>> Komiketto?), otherwise known as the Comic Market (コミックマーケット Komikku
> >>>> Māketto?), is the world's largest dōjinshi fair, held twice a year in
> Tokyo,
> >>>> Japan."
> >>>>
> >>>> ~590,000 people attended comiket last summer. It basically looks like
> >>>> http://en.wikipedia.org/wiki/File:Comiket77.jpg
> >>>>
> >>>> With hundreds of thousands of people in a small area, asynchronous IRC
> >>>> becomes fun.
> >>>> Not as fun as the near-synchronous one we have now, but still.
> >>>>
> >>>> I think asynchronous IRC may entice people to adopt EdgeNet starting
> >>>> from big meetups.
> >>>
> >>>
> >>> _______________________________________________
> >>> zeromq-dev mailing list
> >>> zeromq-dev at lists.zeromq.org
> >>> http://lists.zeromq.org/mailman/listinfo/zeromq-dev
> >>>
> >>>
> >>> _______________________________________________
> >>> zeromq-dev mailing list
> >>> zeromq-dev at lists.zeromq.org
> >>> http://lists.zeromq.org/mailman/listinfo/zeromq-dev
> >>>
> >>
> >> _______________________________________________
> >> zeromq-dev mailing list
> >> zeromq-dev at lists.zeromq.org
> >> http://lists.zeromq.org/mailman/listinfo/zeromq-dev
> >>
> >
> >
> > _______________________________________________
> > zeromq-dev mailing list
> > zeromq-dev at lists.zeromq.org
> > http://lists.zeromq.org/mailman/listinfo/zeromq-dev
> >
> _______________________________________________
> zeromq-dev mailing list
> zeromq-dev at lists.zeromq.org
> http://lists.zeromq.org/mailman/listinfo/zeromq-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20140106/085db740/attachment.htm>


More information about the zeromq-dev mailing list