com.stackify.api.common.http
public class HttpResendQueue extends Object
| Constructor and Description |
|---|
HttpResendQueue(int maxSize)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
drain(HttpClient httpClient,
String path)
Drains the resend queue until empty or error
|
void |
drain(HttpClient httpClient,
String path,
boolean gzip)
Drains the resend queue until empty or error
|
void |
offer(byte[] request,
HttpException e)
Offers a failed request to the resend queue
|
void |
offer(byte[] request,
IOException e)
Offers a failed request to the resend queue
|
int |
size() |
public HttpResendQueue(int maxSize)
maxSize - Maximum size of the queuepublic int size()
public void offer(byte[] request,
IOException e)
request - The failed requeste - IOExceptionpublic void offer(byte[] request,
HttpException e)
request - The failed requeste - HttpExceptionpublic void drain(HttpClient httpClient, String path)
httpClient - The HTTP clientpath - REST pathpublic void drain(HttpClient httpClient, String path, boolean gzip)
httpClient - The HTTP clientpath - REST pathgzip - True if the post should be gzipped, false otherwiseCopyright © 2016 Stackify, LLC. All Rights Reserved.