fixing the thread creation in airavata-api