@UriParams public class NatsConfiguration extends Object
| Constructor and Description |
|---|
NatsConfiguration() |
| Modifier and Type | Method and Description |
|---|---|
io.nats.client.Options.Builder |
createOptions() |
io.nats.client.Connection |
getConnection()
Reference an already instantiated connection to Nats server
|
int |
getConnectionTimeout()
Timeout for connection attempts.
|
int |
getFlushTimeout() |
String |
getMaxMessages()
Stop receiving messages from a topic we are subscribing to after maxMessages
|
int |
getMaxPingsOut()
maximum number of pings have not received a response allowed by the client
|
int |
getMaxReconnectAttempts()
Max reconnection attempts
|
int |
getPingInterval()
Ping interval to be aware if connection is still alive (in milliseconds)
|
int |
getPoolSize()
Consumer thread pool size (default is 10)
|
String |
getQueueName()
The Queue name if we are using nats for a queue configuration
|
int |
getReconnectTimeWait()
Waiting time before attempts reconnection (in milliseconds)
|
String |
getReplySubject()
the subject to which subscribers should send response
|
int |
getRequestCleanupInterval()
Interval to clean up cancelled/timed out requests.
|
long |
getRequestTimeout() |
String |
getServers()
URLs to one or more NAT servers.
|
org.apache.camel.support.jsse.SSLContextParameters |
getSslContextParameters()
To configure security using SSLContextParameters
|
String |
getTopic()
The name of topic we want to use
|
boolean |
isFlushConnection() |
boolean |
isNoEcho()
Turn off echo.
|
boolean |
isNoRandomizeServers()
Whether or not randomizing the order of servers for the connection attempts
|
boolean |
isPedantic()
Whether or not running in pedantic mode (this affects performance)
|
boolean |
isReconnect()
Whether or not using reconnection feature
|
boolean |
isReplyToDisabled() |
boolean |
isSecure()
Set secure option indicating TLS is required
|
boolean |
isTraceConnection()
Whether or not connection trace messages should be printed to standard out for fine grained debugging of
connection issues.
|
boolean |
isVerbose()
Whether or not running in verbose mode
|
void |
setConnection(io.nats.client.Connection connection) |
void |
setConnectionTimeout(int connectionTimeout) |
void |
setFlushConnection(boolean flushConnection)
Define if we want to flush connection when stopping or not
|
void |
setFlushTimeout(int flushTimeout)
Set the flush timeout (in milliseconds)
|
void |
setMaxMessages(String maxMessages) |
void |
setMaxPingsOut(int maxPingsOut) |
void |
setMaxReconnectAttempts(int maxReconnectAttempts) |
void |
setNoEcho(boolean noEcho) |
void |
setNoRandomizeServers(boolean noRandomizeServers) |
void |
setPedantic(boolean pedantic) |
void |
setPingInterval(int pingInterval) |
void |
setPoolSize(int poolSize) |
void |
setQueueName(String queueName) |
void |
setReconnect(boolean reconnect) |
void |
setReconnectTimeWait(int reconnectTimeWait) |
void |
setReplySubject(String replySubject) |
void |
setReplyToDisabled(boolean replyToDisabled)
Can be used to turn off sending back reply message in the consumer.
|
void |
setRequestCleanupInterval(int requestCleanupInterval) |
void |
setRequestTimeout(long requestTimeout)
Request timeout in milliseconds
|
void |
setSecure(boolean secure) |
void |
setServers(String servers) |
void |
setSslContextParameters(org.apache.camel.support.jsse.SSLContextParameters sslContextParameters) |
void |
setTopic(String topic) |
void |
setTraceConnection(boolean traceConnection) |
void |
setVerbose(boolean verbose) |
public String getServers()
public void setServers(String servers)
public String getTopic()
public void setTopic(String topic)
public io.nats.client.Connection getConnection()
public void setConnection(io.nats.client.Connection connection)
public boolean isReconnect()
public void setReconnect(boolean reconnect)
public boolean isPedantic()
public void setPedantic(boolean pedantic)
public boolean isVerbose()
public void setVerbose(boolean verbose)
public int getReconnectTimeWait()
public void setReconnectTimeWait(int reconnectTimeWait)
public int getMaxReconnectAttempts()
public void setMaxReconnectAttempts(int maxReconnectAttempts)
public int getMaxPingsOut()
public void setMaxPingsOut(int maxPingsOut)
public int getRequestCleanupInterval()
public void setRequestCleanupInterval(int requestCleanupInterval)
public void setRequestTimeout(long requestTimeout)
public long getRequestTimeout()
public int getPingInterval()
public void setPingInterval(int pingInterval)
public int getConnectionTimeout()
public void setConnectionTimeout(int connectionTimeout)
public String getReplySubject()
public void setReplySubject(String replySubject)
public boolean isNoRandomizeServers()
public void setNoRandomizeServers(boolean noRandomizeServers)
public boolean isNoEcho()
public void setNoEcho(boolean noEcho)
public String getQueueName()
public void setQueueName(String queueName)
public boolean isReplyToDisabled()
public void setReplyToDisabled(boolean replyToDisabled)
public String getMaxMessages()
public void setMaxMessages(String maxMessages)
public int getPoolSize()
public void setPoolSize(int poolSize)
public boolean isFlushConnection()
public void setFlushConnection(boolean flushConnection)
public int getFlushTimeout()
public void setFlushTimeout(int flushTimeout)
public boolean isSecure()
public void setSecure(boolean secure)
public org.apache.camel.support.jsse.SSLContextParameters getSslContextParameters()
public void setSslContextParameters(org.apache.camel.support.jsse.SSLContextParameters sslContextParameters)
public io.nats.client.Options.Builder createOptions()
throws NoSuchAlgorithmException,
IllegalArgumentException
public boolean isTraceConnection()
public void setTraceConnection(boolean traceConnection)
Apache Camel