Exemple #1
0
 def __init__(self, log_file, output_file, no_compression):
     self.log_manager = log_manager.LogManager()
     self.stop_watch = timer.Timer()
     self.setup_logging(log_file)
     self.command_executor = CommandExecutor(output_file)
     self.compress = not no_compression
     self.http = HttpManager()
 def __init__(self, log_file, output_file, no_compression, debug=False):
     self.debug = debug
     self.log_manager = log_manager.LogManager()
     self.stop_watch = timer.Timer()
     self.setup_logging(log_file)
     try:
         with open(output_file, 'a+'):
             pass
     except Exception as error:
         self.logger.error('Output file error: %s',
                           str(error),
                           exc_info=self.debug)
         raise
     self.command_executor = CommandExecutor(output_file)
     self.compress = not no_compression
     self.http = HttpManager()