commit | 99b6f04824681cb5a687bc5c3f49d53ccada500a | [log] [tgz] |
---|---|---|
author | Matthieu Morel <mmorel@apache.org> | Sat May 19 20:15:47 2012 +0200 |
committer | Matthieu Morel <mmorel@apache.org> | Sat May 19 20:15:47 2012 +0200 |
tree | 97eb8e62852fe203cec4ecff414d30904d4f7c87 | |
parent | a63cda911ac0b386a9a9b88344cfc5ead32d7fe7 [diff] |
inter-app communications + refactorings - applications publish streams they produce and streams they consume - RemoteStream instances send messages to remote consumers, identified by (cluster, appId), through multiple senders and emitters (1 per consumer cluster) - added related tests - removed file-based cluster configuration: cluster configuration is now through ZooKeeper only - renamed Topology to Cluster, and Cluster to PhysicalCluster - improved tests, minimized the number of configuration files - commented out code for supporting network glitches: it blocked the sending of messages upon cluster disconnections - migrated to gradle 1.0-rc-3 , so that we can embed build operations with parameters
The goal of this project is to incorporate feedback from various users and create a prototype with a cleaner, simpler API. The base classes are the foundation on top of which higher level layers and tools can be built. For example, one could write a domain specific language to create the application graph. Look at this as the foundation and not as the end product.
Here is a list of ideas:
Please post feedback and suggestions in the s4 forum.
The repo is here:
https://github.com/leoneu/s4-piper
In this version:
Note that when we create a PE in App, we are really creating a prototype of the PE. The actual PE instances get created every time a node receives an event that is dispatched to a specific PE prototype. The first PE has Map that holds the instances by a specific key. PE instances are clones which means that we don't call the constructor. Instead we provide an init method. Also, the instance variables are cloned. This means that references are also copied. If you wanted to have a List per PE instance, you would have to create it in the init method. This design pattern, makes thing very simple and efficient but has the downside that programmers have to understand how instances are created via clone.
For now we identify PEs using a composite string produced by KeyFinder. We must also pass the raw data types used to create the composite key. Need to think how to do this with type safety in mind.
Examples: