Example #1
0
 def manage_signal(self, sig, frame):
     # If we got USR1, just dump memory
     if sig == 10:
         self.sched.need_dump_memory = True
     else: # if not, die :)
         self.sched.die()
         self.must_run = False
         Daemon.manage_signal(self, sig, frame)
Example #2
0
 def manage_signal(self, sig, frame):
     logger.warning("Received a SIGNAL %s" % sig)
     # If we got USR1, just dump memory
     if sig == signal.SIGUSR1:
         self.sched.need_dump_memory = True
     elif sig == signal.SIGUSR2: #usr2, dump objects
         self.sched.need_objects_dump = True
     else:  # if not, die :)
         self.sched.die()
         self.must_run = False
         Daemon.manage_signal(self, sig, frame)
Example #3
0
 def manage_signal(self, sig, frame):
     print "MANAGE SIGNAL", sig
     # If we got USR1, just dump memory
     if sig == 10:
         self.sched.need_dump_memory = True
     elif sig == 12: #usr2, dump objects
         self.sched.need_objects_dump = True
     else:  # if not, die :)
         self.sched.die()
         self.must_run = False
         Daemon.manage_signal(self, sig, frame)