public class Publisher
extends java.lang.Object
Constructor and Description |
---|
Publisher() |
Modifier and Type | Method and Description |
---|---|
java.lang.Boolean |
publish(HookRequest request)
Publish the request using the appropriate backoff and retry logic
defined in the Whoas documentation
|
java.lang.Boolean |
shouldRetry(javax.ws.rs.core.Response response)
Determine whether this response meets our criteria for retry
|
public java.lang.Boolean publish(HookRequest request) throws java.lang.InterruptedException
request
- a valid HookRequest
HookRequest
java.lang.InterruptedException
- thrown if our attempts to backoff were interruptedpublic java.lang.Boolean shouldRetry(javax.ws.rs.core.Response response)
response
- Response
which has a status to determine our retry