Sha256: 06ab6f6c7e58affb888b25c002af45814882086e1a1f305d6fc403c117dcdfc5
Contents?: true
Size: 650 Bytes
Versions: 3
Compression:
Stored size: 650 Bytes
Contents
# Retry Interceptor If you enable the retry interceptor, you can have lhc retry requests for you: ```ruby LHC.config.interceptors = [LHC::Retry] response = LHC.get('http://local.ch', retry: true) ``` It will try to retry the request up to 3 times (default) internally, before it passes the last response back, or raises an error for the last response. Consider, that all other interceptors will run for every single retry. ## Limit the amount of retries while making the request ```ruby LHC.get('http://local.ch', retry: { max: 1 }) ``` ## Change the default maximum of retries of the retry interceptor ```ruby LHC::Retry.max = 3 ```
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
lhc-6.7.2 | docs/interceptors/retry.md |
lhc-6.7.1 | docs/interceptors/retry.md |
lhc-6.7.0 | docs/interceptors/retry.md |