(signum, frame)
This will close connections cleanly
This will close connections cleanly
This will close connections cleanly
def killhandle(signum, frame):
    ''' This will close connections cleanly '''
    line = "SIGTERM detected, shutting down"
    syslog.syslog(syslog.LOG_INFO, line)
    rdb_server.close()
    # zsend.close()  # zsend?
    syslog.closelog()
    sys.exit(0)
def killhandle ( signum , frame ) : line = "SIGTERM detected, shutting down" syslog . syslog ( syslog . LOG_INFO , line ) rdb_server . close ( ) # zsend.close()  # zsend? syslog . closelog ( ) sys . exit ( 0 )