merge thread class