def __call__(self): layer = http.HttpLayer(self, self.mode) try: layer() except exceptions.ProtocolException as e: self.log(repr(e), "info") self.log(traceback.format_exc(), "debug") self.zombie = time.time()
def run(self): layer = http.HttpLayer(self, self.mode) try: layer() except exceptions.ProtocolException as e: # pragma: no cover self.log(repr(e), "info") self.log(traceback.format_exc(), "debug") except exceptions.Kill: self.log("Connection killed", "info") if not self.zombie: self.zombie = time.time()
def run(self): layer = http.HttpLayer(self, self.mode) try: layer() except exceptions.ProtocolException as e: # pragma: no cover self.log(repr(e), "info") self.log(traceback.format_exc(), "debug") except exceptions.SetServerNotAllowedException as e: # pragma: no cover self.log( "Changing the Host server for HTTP/2 connections not allowed: {}" .format(e), "info") except exceptions.Kill: self.log("Connection killed", "info") if not self.zombie: self.zombie = time.time()
def __call__(self): layer = http.HttpLayer(self, self.mode) layer()