add thread specific and test it