Refactoring. Separated PLC Object, PYRO Server and MainWorker :
- PLC Object is now a Singleton, instantiated through runtime.CreatePLCObjectSingleton(...)
- Pyro server doesn't hold any reference to PLCObject, and doesn't create it anymore
- PLC Object class doesn't inherit from Pyro.ObjBase anymore
- Pyro related code moved to runtime.PyroServer.py
- MainWorker class moved to runtime/Worker.py
- Both PLC Object and MainWorker creation happens in runtime/__init__.py
{
"version": 2,
"controller": {},
"workers": [
{
"type": "router",
"options": {
"pythonpath": [
".."
]
},
"realms": [
{
"name": "Automation",
"roles": [
{
"name": "anonymous",
"permissions": [
{
"uri": "",
"match": "prefix",
"allow": {
"call": true,
"register": true,
"publish": true,
"subscribe": true
},
"disclose": {
"caller": false,
"publisher": false
},
"cache": true
}
]
}
]
}
],
"transports": [
{
"type": "websocket",
"debug": true,
"endpoint": {
"type": "tcp",
"port": 8888
},
"url": "ws://127.0.0.1:8888/",
"serializers": [
"msgpack",
"json"
]
}
]
}
]
}