mirror of
https://github.com/avatao-content/baseimage-tutorial-framework
synced 2025-06-28 14:35:11 +00:00
OO Refactor event_handler_connector.py temporary solution
This commit is contained in:
10
lib/util.py
10
lib/util.py
@ -1,4 +1,4 @@
|
||||
import json, xmlrpc.client
|
||||
import json, xmlrpc.client, zmq
|
||||
|
||||
from config.envvars import SUPERVISOR_HTTP_URI
|
||||
|
||||
@ -15,5 +15,11 @@ def create_source_code_response_data(filename, content, language):
|
||||
'language': language
|
||||
}
|
||||
|
||||
|
||||
class SupervisorMixin:
|
||||
supervisor = xmlrpc.client.ServerProxy(SUPERVISOR_HTTP_URI).supervisor
|
||||
supervisor = xmlrpc.client.ServerProxy(SUPERVISOR_HTTP_URI).supervisor
|
||||
|
||||
|
||||
class ZMQConnectorBase:
|
||||
def __init__(self, zmq_context=None):
|
||||
self._zmq_context = zmq_context or zmq.Context.instance()
|
||||
|
Reference in New Issue
Block a user