Created
March 17, 2017 16:56
-
-
Save mager/997456e1349db9c6dc6a78b05198f7a0 to your computer and use it in GitHub Desktop.
Simple consul_mut_ex example using do...while block
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
iex> ConsulMutEx.lock(“test_key”, max_retries: 0) do | |
...> :acquired | |
...> else | |
...> :failed_to_acquire | |
...> end | |
:acquired |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment