public class HttpHook extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
CONNECTION_POOL_SIZE_DEFAULT_VALUE |
static String |
CONNECTION_POOL_SIZE_PROPERTY_NAME |
| Constructor and Description |
|---|
HttpHook(String destination)
Creates a new hook.
|
| Modifier and Type | Method and Description |
|---|---|
Integer |
getConnectionPoolSize() |
String |
getDestination()
The destination of the hook.
|
Optional<org.joda.time.LocalDateTime> |
getExpirationTime() |
Pattern |
getFilter()
Returns the precompiled pattern, to match
a given url.
|
org.swisspush.gateleen.core.http.HeaderFunction |
getHeaderFunction() |
HookTriggerType |
getHookTriggerType()
Retuns the trigger type of the hook.
|
List<String> |
getMethods()
Returns the methods which should pass the hook.
|
io.vertx.core.net.ProxyOptions |
getProxyOptions()
Get custom proxy options for this hook
|
int |
getQueueExpireAfter()
Gets the expiry (x-queue-expire-after header)
for the requests in the queue send to the
listener.
|
QueueingStrategy |
getQueueingStrategy()
Returns the queueing strategy for the hook
|
boolean |
isCollection()
Indicates if a hook points to a collection (default: true)
or not.
|
boolean |
isFullUrl()
Returns whether the hook forwards using the full initial url or only the appendix.
|
boolean |
isListable()
Indicates if a route hook should be listed
for a GET request or not.
|
void |
setCollection(boolean collection)
Sets if a hook points to a collection (default: true)
or not.
|
void |
setConnectionPoolSize(Integer connectionPoolSize)
|
void |
setDestination(String destination)
Sets the destination of the hook.
|
void |
setExpirationTime(org.joda.time.LocalDateTime expirationTime)
Sets the expiration time of this hook.
|
void |
setFilter(String regex)
Set a regexp to filter the hook.
|
void |
setFullUrl(boolean fullUrl)
Sets whether the hook forwards using the full initial url or only the appendix.
|
void |
setHeaderFunction(org.swisspush.gateleen.core.http.HeaderFunction headerFunction) |
void |
setHookTriggerType(HookTriggerType hookTriggerType)
Sets the trigger type of the hook.
|
void |
setListable(boolean listable)
Sets if a route hook should be listed
for a GET request or not.
|
void |
setMethods(List<String> methods)
Sets the methods which should pass the hook.
|
void |
setProxyOptions(io.vertx.core.net.ProxyOptions proxyOptions)
Set custom proxy options for this hook
|
void |
setQueueExpireAfter(int queueExpireAfter)
Sets the expiry (x-queue-expire-after header)
for the requests in the queue send to the
listener.
|
void |
setQueueingStrategy(QueueingStrategy queueingStrategy)
Sets the queueing strategy for the hook
|
public static final String CONNECTION_POOL_SIZE_PROPERTY_NAME
public static final int CONNECTION_POOL_SIZE_DEFAULT_VALUE
public HttpHook(String destination)
destination - destinationpublic String getDestination()
public void setDestination(String destination)
destination - destinationpublic List<String> getMethods()
public void setMethods(List<String> methods)
methods - a list of HTTP methods or empty, if all methods do pass.public Optional<org.joda.time.LocalDateTime> getExpirationTime()
public void setExpirationTime(org.joda.time.LocalDateTime expirationTime)
expirationTime - expirationTimepublic boolean isFullUrl()
public void setFullUrl(boolean fullUrl)
fullUrl - fullUrlpublic QueueingStrategy getQueueingStrategy()
public void setQueueingStrategy(QueueingStrategy queueingStrategy)
queueingStrategy - public Pattern getFilter()
public void setFilter(String regex)
regex - - a regular expressionpublic int getQueueExpireAfter()
public void setQueueExpireAfter(int queueExpireAfter)
queueExpireAfter - - a value in secondspublic org.swisspush.gateleen.core.http.HeaderFunction getHeaderFunction()
public void setHeaderFunction(org.swisspush.gateleen.core.http.HeaderFunction headerFunction)
public HookTriggerType getHookTriggerType()
public void setHookTriggerType(HookTriggerType hookTriggerType)
hookTriggerType - the trigger type of the hookpublic boolean isListable()
public void setListable(boolean listable)
listable - true if the route hook should be listedpublic boolean isCollection()
public void setCollection(boolean collection)
collection - true (default) if hook points to collection.public Integer getConnectionPoolSize()
public void setConnectionPoolSize(Integer connectionPoolSize)
public io.vertx.core.net.ProxyOptions getProxyOptions()
nullpublic void setProxyOptions(io.vertx.core.net.ProxyOptions proxyOptions)
proxyOptions - the custom proxy options to setCopyright © 2016–2019. All rights reserved.