retry_once
It retries a block of code, but only once... you can try and recover with a custom proc/lambda/whatevery.
usage
retry_exception_once_with(SomeRandomError, lambda { doSomething }) do
puts "This is a try!"
raise SomeRandomError
end
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign up| Failed to load latest commit information. | |||
|
|
lib | ||
|
|
.gitignore | ||
|
|
LICENSE | ||
|
|
README.md | ||
|
|
retry_once.gemspec | ||
It retries a block of code, but only once... you can try and recover with a custom proc/lambda/whatevery.
retry_exception_once_with(SomeRandomError, lambda { doSomething }) do
puts "This is a try!"
raise SomeRandomError
end