Ejemplo n.º 1
0
    def startFactory(self):
        WampServerFactory.startFactory(self)
        log.msg("AdminWebSocketFactory started [speaking %s]" % self.protocols)

        log.msg("debugWamp: %s" % self.debugWamp)
        log.msg("debugApp: %s" % self.debugApp)

        self.updateAvailable = {"update-available": False}
        self.autocheckForUpdates()
Ejemplo n.º 2
0
   def startFactory(self):
      WampServerFactory.startFactory(self)
      log.msg("AdminWebSocketFactory started [speaking %s]" % self.protocols)

      log.msg("debugWamp: %s" % self.debugWamp)
      log.msg("debugApp: %s" % self.debugApp)

      self.updateAvailable = {"update-available": False}
      self.autocheckForUpdates()
Ejemplo n.º 3
0
 def startFactory(self):
    WampServerFactory.startFactory(self)
    self.setOptionsFromConfig()
    log.msg("HubWebSocketFactory started [speaking %s, %s]" % (self.protocols, self.versions))
    self.publishStats()
Ejemplo n.º 4
0
 def startFactory(self):
     WampServerFactory.startFactory(self)
     reactor.callLater(5, self.connectGephi)
Ejemplo n.º 5
0
 def startFactory(self):
     if not self._reaper:
         self._reaper = reactor.callLater(self._timeout, lambda: reactor.stop())
     WampServerFactory.startFactory(self)
Ejemplo n.º 6
0
 def startFactory(self):
     if not self._reaper:
         self._reaper = reactor.callLater(self._timeout,
                                          lambda: reactor.stop())
     WampServerFactory.startFactory(self)
Ejemplo n.º 7
0
 def startFactory(self):
     WampServerFactory.startFactory(self)
     global PubSubConnection
     PubSubConnection = self
     reactor.callLater(5, self.connectComment)
Ejemplo n.º 8
0
 def startFactory(self):
    WampServerFactory.startFactory(self)
    reactor.callLater(5, self.connectGephi)
Ejemplo n.º 9
0
    game_map[game_id] = game
    

if __name__ == '__main__':


    # Create game tables
    for i in range(4):
        create_game()

    log.startLogging(sys.stdout)

    g_factory = WampServerFactory("ws://localhost:8080")
    g_factory.protocol = MyServerProtocol

    g_factory.startFactory()

    resource = WebSocketResource(g_factory)

    root = File("web")

    root.putChild("ws", resource)

    site = Site(root)
    site.protocol = HTTPChannelHixie76Aware
    reactor.listenTCP(8080, site)

    reactor.run()