예제 #1
0
 def init_watcher(self):
     try:
         self.watcher = LogWatcher(parent=self, log=self.log)
     except:
         self.log.error("Couldn't start the LogWatcher", exc_info=True)
         self.exit(1)
     self.log.info("Listening for log messages on %r" % self.watcher.url)
예제 #2
0
class IPLoggerApp(BaseParallelApplication):

    name = u'iplogger'
    description = _description
    classes = [LogWatcher, ProfileDir]
    aliases = Dict(aliases)

    @catch_config_error
    def initialize(self, argv=None):
        super(IPLoggerApp, self).initialize(argv)
        self.init_watcher()

    def init_watcher(self):
        try:
            self.watcher = LogWatcher(parent=self, log=self.log)
        except:
            self.log.error("Couldn't start the LogWatcher", exc_info=True)
            self.exit(1)
        self.log.info("Listening for log messages on %r" % self.watcher.url)

    def start(self):
        self.watcher.start()
        try:
            self.watcher.loop.start()
        except KeyboardInterrupt:
            self.log.critical("Logging Interrupted, shutting down...\n")
예제 #3
0
class IPLoggerApp(BaseParallelApplication):

    name = u'iplogger'
    description = _description
    classes = [LogWatcher, ProfileDir]
    aliases = Dict(aliases)

    @catch_config_error
    def initialize(self, argv=None):
        super(IPLoggerApp, self).initialize(argv)
        self.init_watcher()
    
    def init_watcher(self):
        try:
            self.watcher = LogWatcher(parent=self, log=self.log)
        except:
            self.log.error("Couldn't start the LogWatcher", exc_info=True)
            self.exit(1)
        self.log.info("Listening for log messages on %r"%self.watcher.url)
        

    def start(self):
        self.watcher.start()
        try:
            self.watcher.loop.start()
        except KeyboardInterrupt:
            self.log.critical("Logging Interrupted, shutting down...\n")
예제 #4
0
 def init_watcher(self):
     try:
         self.watcher = LogWatcher(parent=self, log=self.log)
     except:
         self.log.error("Couldn't start the LogWatcher", exc_info=True)
         self.exit(1)
     self.log.info("Listening for log messages on %r"%self.watcher.url)