The lock statement ensures that one thread does not enter a critical section of code while another thread is in the critical section. However, it won\'t work if the workload is
There is no way to implement an inter-machine threading control with ASP.NET right now. But this can be implemented via a higher level application architecture. Basically, you would have to implement it yourself using your own business logic.
Architecturally, you should introduce a ILockable interface in your solution, and have classes that need to cease operation at some condition to implement it. Then use a set of Gateways to mutually manage those locks.