added threading for deploy