Distributed Computing Framework
Synapse.tools.dmon is a multi-purpose tool for running a synapse daemon and sharing objects. It allows objects to be created and shared, optionally using a service bus, by config options in a json file rather than requiring custom code for each intended service.
Config dictionaries may be stored as JSON files or passed in programatically. The following examples use JSON syntax and could be loaded from a file.
The following config shares a ram:/// cortex as the object "foo" and listens via both the local socket "mysock" and tcp loopback on port 3344.
{
"ctors":[
["foo","ctor:///synapse.cortex.openurl('ram:///')"]
],
"dmon:share":[
[ "foo", {} ]
],
"dmon:listen":[
"local://mysock/",
"tcp://127.0.0.1:3344"
]
}