adding thread protocol