thread safety changes