示例#1
0
文件: server.py 项目: mash0304/pathos
    def __init__(self, host, port):
        """create a XML-RPC server

Takes two initial inputs:
    host  -- hostname of XML-RPC server host
    port  -- port number for server requests
        """
        Server.__init__(self)
        SimpleXMLRPCDispatcher.__init__(self, allow_none=False, encoding=None)

        self._installSocket(host, port)
        self._activeProcesses = {}  # { fd : pid }
示例#2
0
    def __init__(self, host, port):
        '''create a XML-RPC server

Takes two initial inputs:
    host  -- hostname of XML-RPC server host
    port  -- port number for server requests
        '''
        Server.__init__(self)
        SimpleXMLRPCDispatcher.__init__(self, allow_none=False, encoding=None)

        self._installSocket(host, port)
        self._activeProcesses = {}  #{ fd : pid }
示例#3
0
文件: server.py 项目: mash0304/pathos
    def serve(self):
        """enter the select loop... and wait for service requests"""

        timeout = 5
        Server.serve(self, 5)
示例#4
0
文件: server.py 项目: mash0304/pathos
    def activate(self):
        """install callbacks"""

        Server.activate(self)
        self._selector.notifyOnReadReady(self._socket, self._onConnection)
        self._selector.notifyWhenIdle(self._onSelectorIdle)
示例#5
0
    def serve(self):
        """enter the select loop... and wait for service requests"""

        timeout = 5
        Server.serve(self, 5)
示例#6
0
    def activate(self):
        """install callbacks"""

        Server.activate(self)
        self._selector.notifyOnReadReady(self._socket, self._onConnection)
        self._selector.notifyWhenIdle(self._onSelectorIdle)