Scout24/broway

Name: broway

Owner: AutoScout24

Owner: AutoScout24

Description: PubSub with memory

Created: 2016-06-09 12:15:20.0

Updated: 2016-06-10 07:35:56.0

Pushed: 2016-06-10 10:58:58.0

Homepage: null

Size: 10

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

broway

PubSub with the history. Broway is just a cool name.

Intro

We want to have a way to make modules communicate without thinking which one has been loaded before.

A Reader can reach all the messages that has been sent to the mailbox before it was created:

ailbox('myMailBox').send(1);
ailbox('myMailBox').send('another message');
..
ailbox('myMailBox').read(console.log.bind(console)) // 1 ... 'another message'
s
ailbox('myMailBox').send(1);
ailbox('myMailBox').send('another message');
..
ailbox('myMailBox').read(console.log.bind(console)) // 1 ... 'another message'

ailbox('myMailBox').send(2);
ogs "2" from the first reader

reate another reader
ailbox('myMailBox').read(console.log.bind(console)) // 1, 'another message', 2

ailbox('myMailBox').send(3);
ogs "3" two times as we now have two readers 
Roadmap

broway

PubSub with the history. Broway is just a cool name.

Intro

We want to have a way to make modules communicate without thinking which one has been loaded before.

A Reader can reach all the messages that has been sent to the mailbox before it was created:

ailbox('myMailBox').send(1);
ailbox('myMailBox').send('another message');
..
ailbox('myMailBox').read(console.log.bind(console)) // 1 ... 'another message'
s
ailbox('myMailBox').send(1);
ailbox('myMailBox').send('another message');
..
ailbox('myMailBox').read(console.log.bind(console)) // 1 ... 'another message'

ailbox('myMailBox').send(2);
ogs "2" from the first reader

reate another reader
ailbox('myMailBox').read(console.log.bind(console)) // 1, 'another message', 2

ailbox('myMailBox').send(3);
ogs "3" two times as we now have two readers 
Roadmap

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.