Reputation: 626
Suppose I have a step function with only two tasks: start -> task 1 -> task 2 -> end.
Just wonder if the same thread is used in task 1 and task 2.
The scenario is like this. We set some resources at the beginning of a thread execution. Those resources need to be closed ONLY when the thread ends.
So if task 1 and 2 share the same thread, need to close them at the end of task 2. But if not, then need to close the resource in both task 1 and 2.
Upvotes: 1
Views: 225
Reputation: 200672
No they don't share a CPU thread. They may not even run on the same underlying server.
Upvotes: 4