2016/09/08

Rx Challenge #11 This challenge is practice of building something already exists, by your own. The challenge is to build async lock similar to the functionality of SemaphoreSlim WaitAsync / Release. You can check this post for the functionality of SemaphoreSlim. You can consider the following building block for this challenge: - Concurrent Collection - Interlocked - TaskCompletionSource You can validate your solution against this Test Code Snippet public async Task AsyncLock_Test() { // arrange const int LIMIT = 3; var gate = new TaskCompletionSource<object>(); var barrier = new CountdownEvent(LIMIT); var asyncLock =...