def handle_request(self):
        """
        Handles incoming connections, one at the time.
        """
        try:
            (request, client_address) = self.get_request()

        except socket.error as e:
            # Error handling goes here.
            self.logger.error("error opening the connection: %s" % (
                str(e)))
            for exctn in sys.exc_info():
                print(exctn)
            return

        try:
            self.RequestHandlerClass(request, client_address, self)
        except Exception as e:
            # Error handling goes here.
            self.logger.error('error handling the request: %s' % (
                str(e)))
            for exctn in sys.exc_info():
                print(exctn)
            return
def handle_request ( self ) : try : ( request , client_address ) = self . get_request ( ) except socket . error as e : self . logger . error ( "error opening the connection: %s" % ( str ( e ) ) ) for exctn in sys . exc_info ( ) : print ( exctn ) return try : self . RequestHandlerClass ( request , client_address , self ) except Exception as e : self . logger . error ( 'error handling the request: %s' % ( str ( e ) ) ) for exctn in sys . exc_info ( ) : print ( exctn ) return
Handles incoming connections, one at the time.