add a global load_path for app context
check if thread is alive before trying to kill it