cmp = re.compile(filter[key])
res = cmp.search(log.__getattribute__(key))
if res != None:
- print "found match in log: %s %s ~=~ %s" % (log, key, filter[key])
+ #print "found match in log: %s %s ~=~ %s" % (log, key, filter[key])
if log.time > time.time() - timerange:
print "returning log b/c it occured within time."
return log
MonRecord.__init__(self, data)
return
-class Action(MonRecord):
- def __init__(self, host, data):
- self.host = host
- MonRecord.__init__(self, data)
- return
-
- def deltaDays(self, delta):
- t = datetime.fromtimestamp(self.__dict__['time'])
- d = t + timedelta(delta)
- self.__dict__['time'] = time.mktime(d.timetuple())
-
-