add demo thread exit