Commits

Kaspar Schiess committed 6089b2e

Adds all socket types

Comments (0)

Files changed (20)

web/helpers/menu.rb

+module Menu
+  def menu_link name, link
+    if link == current_page.request_path
+      content_tag('div', name, class: 'col-md-2 menu-item active')
+    else
+      content_tag('div', link_to(name, link), class: 'col-md-2 menu-item')
+    end
+  end
+end

web/source/_menu.slim

+.container.menu
+  .row
+    = menu_link 'ABOUT', 'index.html'
+  .row
+    = menu_link 'PAIR', 'pair.html'
+    = menu_link 'REQ/REP', 'reqrep.html'
+    = menu_link 'PUB/SUB', 'pubsub.html'
+    = menu_link 'SURVEY/RESPOND', 'surveyrespond.html'
+    = menu_link 'PUSH/PULL', 'pushpull.html'
+    = menu_link 'BUS', 'bus.html'
+  .row
+    = menu_link 'DOCUMENTATION', 'documentation.html'
+    = menu_link 'CONTRIB', 'contrib.html'

web/source/bus.html.slim

+---
+title: BUS sockets
+---
+
+= partial(:menu)
+
+.container
+  .row
+    .schema
+      = image_tag 'bus.png'
+
+    .caption
+      | Messages travel to all the participants of the BUS.
+        (except the sender)

web/source/images/bus.png

Added
New image

web/source/images/pubsub.png

Added
New image

web/source/images/pushpull.png

Added
New image

web/source/images/reqrep.png

Added
New image

web/source/images/surveyrespond.png

Added
New image

web/source/index.html.slim

 title: Welcome
 ---
 
-.container.menu
-  .row
-    .col-md-2.menu-item.active ABOUT
-  .row
-    .col-md-2.menu-item= link_to 'PAIR', 'pair.html'
-    .col-md-2.menu-item REQ/REP
-    .col-md-2.menu-item PUB/SUB
-    .col-md-2.menu-item SURVEY/RESPOND
-    .col-md-2.menu-item PUSH/PULL
-    .col-md-2.menu-item BUS
-  .row
-    .col-md-2.menu-item DOCUMENTATION
-    .col-md-2.menu-item CONTRIB
+= partial(:menu)
 
+.container
   .row.text
     .col-md-12
       = partial 'texts/about.markdown'

web/source/pair.html.slim

 ---
-title: Welcome
+title: PAIR sockets
 ---
 
-.container.menu
-  .row
-    .col-md-2.menu-item= link_to 'ABOUT', 'index.html'
-  .row
-    .col-md-2.menu-item.active PAIR
-    .col-md-2.menu-item REQ/REP
-    .col-md-2.menu-item PUB/SUB
-    .col-md-2.menu-item SURVEY/RESPOND
-    .col-md-2.menu-item PUSH/PULL
-    .col-md-2.menu-item BUS
-  .row
-    .col-md-2.menu-item DOCUMENTATION
-    .col-md-2.menu-item CONTRIB
+= partial(:menu)
 
+.container
   .row
     .schema
       = image_tag 'pair.png'

web/source/pubsub.html.slim

+---
+title: PUB/SUB sockets
+---
+
+= partial(:menu)
+
+.container
+  .row
+    .schema
+      = image_tag 'pubsub.png'
+
+    .caption
+      | Messages travel from the Publisher to the Subscribers.

web/source/pushpull.html.slim

+---
+title: PUSH/PULL sockets
+---
+
+= partial(:menu)
+
+.container
+  .row
+    .schema
+      = image_tag 'pushpull.png'
+
+    .caption
+      | Messages travel from source nodes to sink nodes 
+        in a fair load balanced manner.

web/source/reqrep.html.slim

+---
+title: REQ/REP sockets
+---
+
+= partial(:menu)
+
+.container
+  .row
+    .schema
+      = image_tag 'reqrep.png'
+
+    .caption
+      | Messages travel from a REQ node (client) 
+        to a REP node (service)
+        and back again.
+
+  .row.text
+    .col-md-6.sample
+      = partial 'texts/req_node.markdown'
+    .col-md-6.sample
+      = partial 'texts/rep_node.markdown'
+

web/source/stylesheets/nanomsg.css.sass

 .menu
   padding-top: 30px
 .menu-item
-  padding-top: 15px
-
-  a 
-    text-decoration: none
-    color: #333
+  font-size: 1.1em
+  padding-top: 5px
 
   &.active
-    padding-top: 0
-    font-size: 200%
 
 .schema
   padding-top: 40px

web/source/surveyrespond.html.slim

+---
+title: SURVEY/RESPOND sockets
+---
+
+= partial(:menu)
+
+.container
+  .row
+    .schema
+      = image_tag 'surveyrespond.png'
+
+    .caption
+      | Messages travel from the Surveyor to all Surveyees and back
+        (within the deadline)

web/source/texts/_about.markdown

 
 # NAME
 
-NanoMsg - Simple IPC using topologies, not transports.
+NanoMsg - Ruby bindings for the [nanomsg](http://nanomsg.org/) library for MRI
+Ruby. 
 
 # VERSION
 

web/source/texts/_pair_a.markdown

 require 'nanomsg'
 
 socket = NanoMsg::PairSocket.new
-socket.connect 'inproc://b'
+socket.bind 'tcp://127.0.0.1:4567'
 socket.send 'm1'
 ```

web/source/texts/_pair_b.markdown

 require 'nanomsg'
 
 socket = NanoMsg::PairSocket.new
-socket.bind 'inproc://b'
+socket.connect 'tcp://127.0.0.1:4567'
 socket.recv # => 'm1'
 ```

web/source/texts/_rep_node.markdown

Empty file added.

web/source/texts/_req_node.markdown

Empty file added.