def run(self):
        self.__load_checkpoints()
        if isinstance(self.__api, NewApi):
            self._logger.info("Using new Evt API")
        if isinstance(self.__api, OldApi):
            self._logger.info("Evt API not detected.  Using older EventLog API")

        ScalyrMonitor.run(self)
    def run( self ):
        self.__load_checkpoints()
        if isinstance( self.__api, NewApi ):
            self._logger.info( "Using new Evt API" )
        if isinstance( self.__api, OldApi ):
            self._logger.info( "Evt API not detected.  Using older EventLog API" )

        ScalyrMonitor.run( self )
    def run(self):
        # workaround a multithread initialization problem with time.strptime
        # see: http://code-trick.com/python-bug-attribute-error-_strptime/
        # we can ignore the result
        tm = time.strptime("2016-08-29", "%Y-%m-%d")

        self.__container_checker.start()

        ScalyrMonitor.run(self)
    def run( self ):
        self.__load_checkpoints()
        self.containers = self.__get_running_containers( self.__socket_file )
        self.docker_logs = self.__get_docker_logs( self.containers )
        self.docker_loggers = []

        #create and start the DockerLoggers
        for log in self.docker_logs:
            if self.__log_watcher:
                log['log_config'] = self.__log_watcher.add_log_config( self, log['log_config'] )
            self.docker_loggers.append( self.__create_docker_logger( log ) )

        self._logger.info( "Initialization complete.  Starting docker monitor for Scalyr" )
        ScalyrMonitor.run( self )
示例#5
0
    def run(self):
        self.__load_checkpoints()
        self.containers = self.__get_running_containers(self.__socket_file)
        self.docker_logs = self.__get_docker_logs(self.containers)
        self.docker_loggers = []

        #create and start the DockerLoggers
        for log in self.docker_logs:
            if self.__log_watcher:
                log['log_config'] = self.__log_watcher.add_log_config(
                    self, log['log_config'])
            self.docker_loggers.append(self.__create_docker_logger(log))

        self._logger.info(
            "Initialization complete.  Starting docker monitor for Scalyr")
        ScalyrMonitor.run(self)
示例#6
0
    def run( self ):
        # get the current debug flags
        self._old_debug_flags = gc.get_debug()

        if self._monitor_all_unreachable:
            # and set the new ones we are interested in
            gc.set_debug( gc.DEBUG_SAVEALL )

        # Output some log information here so we can tell from the logs when the garbage monitor has been reloaded
        self._logger.info( "Starting garbage monitor. Outputting max %d types" % self._max_type_dump )
        if len( self._object_dump_types ):
            self._logger.info( "\tDumping %d objects of type(s) %s" % (self._max_object_dump, str( self._object_dump_types ) ) )
        else:
            self._logger.info( "\tNot dumping individual objects." )
            
        ScalyrMonitor.run( self )
示例#7
0
    def run(self):
        # get the current debug flags
        self._old_debug_flags = gc.get_debug()

        if self._monitor_all_unreachable:
            # and set the new ones we are interested in
            gc.set_debug(gc.DEBUG_SAVEALL)

        # Output some log information here so we can tell from the logs when the garbage monitor has been reloaded
        self._logger.info("Starting garbage monitor. Outputting max %d types" %
                          self._max_type_dump)
        if len(self._object_dump_types):
            self._logger.info("\tDumping %d objects of type(s) %s" %
                              (self._max_object_dump,
                               six.text_type(self._object_dump_types)))
        else:
            self._logger.info("\tNot dumping individual objects.")

        ScalyrMonitor.run(self)
示例#8
0
 def run(self):
     self.log_manager.set_log_watcher(self._log_watcher)
     self._checkpoint = load_checkpoints(self._checkpoint_file)
     self._reset_journal()
     ScalyrMonitor.run(self)
示例#9
0
 def run(self):
     # create the SnmpEngine
     self.__snmpEngine = SnmpEngine()
     ScalyrMonitor.run(self)
示例#10
0
 def run(self):
     self._checkpoint = load_checkpoints(self._checkpoint_file)
     self._reset_journal()
     ScalyrMonitor.run(self)
    def run( self ):
        self.__load_checkpoints()

        ScalyrMonitor.run( self )