Last active
          May 3, 2017 13:35 
        
      - 
      
- 
        Save kaos/09720c6838bbfb7b281a to your computer and use it in GitHub Desktop. 
Revisions
- 
        kaos revised this gist May 14, 2014 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewingThis file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -4,7 +4,7 @@ # other errors in concept or layout with regard to how the queues and # topics work. interface Broker { publish (message :Message, topic :Topic) -> (result :Result); subscribe (subscriber :Subscriber, topic :Topic) -> (result: Result); } 
- 
        kaos revised this gist May 14, 2014 . 1 changed file with 15 additions and 3 deletions.There are no files selected for viewingThis file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -5,8 +5,8 @@ # topics work. interface MessageQueue { publish (message :Message, topic :Topic) -> (result :Result); subscribe (subscriber :Subscriber, topic :Topic) -> (result: Result); } struct Topic { @@ -24,5 +24,17 @@ struct Message { } interface Subscriber { handle_message (message :Message, topic :Topic) -> (result: Result); } struct Result { union { ok :Void; # all ok failed :Failure; # ... other results? } struct Failure { # define failures here.. } } 
- 
        kaos created this gist May 14, 2014 .There are no files selected for viewingThis file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,28 @@ @0xe425876d9fb9589c # Disclaimer, I'm no pubsub expert, so there may be inconsitencies and # other errors in concept or layout with regard to how the queues and # topics work. interface MessageQueue { publish (message :Message, topic :Topic); subscribe (subscriber :Subscriber, topic :Topic); } struct Topic { id :Text; # ...? } struct Message { # from: Id; ? union { text :Text; data :Data; # ... } } interface Subscriber { handle_message (message :Message, topic :Topic); }