public class StompServerOptions extends NetServerOptions implements StompOptions
| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_MAX_BODY_LENGTH |
static int |
DEFAULT_MAX_FRAME_IN_TRANSACTION |
static int |
DEFAULT_MAX_HEADER_LENGTH |
static int |
DEFAULT_MAX_HEADERS |
static int |
DEFAULT_MAX_SUBSCRIPTIONS_BY_CLIENT |
static int |
DEFAULT_TRANSACTION_CHUNK_SIZE |
static String |
DEFAULT_WEBSOCKET_PATH |
DEFAULT_ACCEPT_BACKLOG, DEFAULT_CLIENT_AUTH, DEFAULT_HOST, DEFAULT_PORT, DEFAULT_PROXY_PROTOCOL_TIMEOUT, DEFAULT_PROXY_PROTOCOL_TIMEOUT_TIME_UNIT, DEFAULT_REGISTER_WRITE_HANDLER, DEFAULT_SNI, DEFAULT_USE_PROXY_PROTOCOLDEFAULT_ENABLED_SECURE_TRANSPORT_PROTOCOLS, DEFAULT_IDLE_TIMEOUT, DEFAULT_IDLE_TIMEOUT_TIME_UNIT, DEFAULT_READ_IDLE_TIMEOUT, DEFAULT_SO_LINGER, DEFAULT_SSL, DEFAULT_SSL_ENGINE, DEFAULT_SSL_HANDSHAKE_TIMEOUT, DEFAULT_SSL_HANDSHAKE_TIMEOUT_TIME_UNIT, DEFAULT_TCP_CORK, DEFAULT_TCP_FAST_OPEN, DEFAULT_TCP_KEEP_ALIVE, DEFAULT_TCP_NO_DELAY, DEFAULT_TCP_QUICKACK, DEFAULT_TCP_USER_TIMEOUT, DEFAULT_USE_ALPN, DEFAULT_WRITE_IDLE_TIMEOUTDEFAULT_LOG_ACTIVITY_FORMAT, DEFAULT_LOG_ENABLED, DEFAULT_RECEIVE_BUFFER_SIZE, DEFAULT_REUSE_ADDRESS, DEFAULT_REUSE_PORT, DEFAULT_SEND_BUFFER_SIZE, DEFAULT_TRAFFIC_CLASSDEFAULT_STOMP_HEARTBEAT, DEFAULT_STOMP_HOST, DEFAULT_STOMP_PORT, DEFAULT_SUPPORTED_VERSIONS, DEFAULT_TRAILING_LINE, UTF_8| Constructor and Description |
|---|
StompServerOptions()
Default constructor.
|
StompServerOptions(JsonObject json)
Create an instance from a
JsonObject. |
StompServerOptions(StompServerOptions other)
Copy constructor.
|
| Modifier and Type | Method and Description |
|---|---|
JsonObject |
getHeartbeat()
Gets the heartbeat configuration.
|
int |
getMaxBodyLength()
Gets the max length of the frame body accepted by the server.
|
int |
getMaxFrameInTransaction()
Gets the maximum number of frames that can be added to a transaction.
|
int |
getMaxHeaderLength()
Gets the max length of header's value.
|
int |
getMaxHeaders()
Gets the maximum number of headers supported by the server.
|
int |
getMaxSubscriptionsByClient()
Gets the maximum of subscriptions a client is allowed to register.
|
int |
getPort() |
List<String> |
getSupportedVersions()
Gets the STOMP protocol versions supported by the server.
|
int |
getTimeFactor()
Gets the time factor, i.e.
|
int |
getTransactionChunkSize()
Gets the chunk size when replaying a transaction.
|
String |
getWebsocketPath()
Gets the path for the web socket.
|
boolean |
isSecured()
Checks whether or not the server is secured (meaning it has an authentication mechanism).
|
boolean |
isSendErrorOnNoSubscriptions()
Checks whether or not an error is sent to the client when this client sends a message to an not subscribed
destinations (no subscriptions on this destination).
|
boolean |
isTrailingLine()
Gets whether or not an empty line should be appended to the written STOMP frame.
|
boolean |
isWebsocketBridge()
Checks whether or not the web socket bridge is enabled.
|
StompServerOptions |
setHeartbeat(JsonObject heartbeat)
Sets the heartbeat configuration.
|
StompServerOptions |
setHost(String host)
Set the host
|
StompServerOptions |
setMaxBodyLength(int maxBodyLength)
Sets the max body length accepted by the server.
|
StompServerOptions |
setMaxFrameInTransaction(int maxFrameInTransaction)
Sets the maximum number of frame that can be added in a transaction.
|
StompServerOptions |
setMaxHeaderLength(int maxHeaderLength)
Sets the max header length.
|
StompServerOptions |
setMaxHeaders(int maxHeaders)
Sets the maximum number of headers.
|
StompServerOptions |
setMaxSubscriptionsByClient(int maxSubscriptionsByClient)
Sets the maximum of subscriptions a client is allowed to register.
|
StompServerOptions |
setPort(int port)
Sets the port on which the server is going to listen for TCP connection.
|
StompServerOptions |
setSecured(boolean secured)
Enables or disables the server security feature.
|
StompServerOptions |
setSendErrorOnNoSubscriptions(boolean sendErrorOnNoSubscriptions)
Sets whether or not an error is sent to the client when this client sends a message to an not subscribed
destinations (no subscriptions on this destination).
|
StompServerOptions |
setSsl(boolean ssl)
Set whether SSL/TLS is enabled
|
StompServerOptions |
setSupportedVersions(List<String> supportedVersions)
Sets the STOMP protocol versions supported by the server.
|
StompServerOptions |
setTimeFactor(int timeFactor)
Sets the time factor.
|
StompServerOptions |
setTrailingLine(boolean trailingLine)
Sets whether or not an empty line should be appended to the written STOMP frame.
|
StompServerOptions |
setTransactionChunkSize(int transactionChunkSize)
Sets the chunk size when replaying a transaction.
|
StompServerOptions |
setWebsocketBridge(boolean websocketBridge)
Enables or disables the web socket bridge.
|
StompServerOptions |
setWebsocketPath(String websocketPath)
Sets the websocket path.
|
JsonObject |
toJson()
Convert to JSON
|
addCrlPath, addCrlValue, addEnabledCipherSuite, addEnabledSecureTransportProtocol, getAcceptBacklog, getClientAuth, getHost, getProxyProtocolTimeout, getProxyProtocolTimeoutUnit, isRegisterWriteHandler, isSni, isUseProxyProtocol, removeEnabledCipherSuite, removeEnabledSecureTransportProtocol, setAcceptBacklog, setActivityLogDataFormat, setClientAuth, setEnabledSecureTransportProtocols, setIdleTimeout, setIdleTimeoutUnit, setJdkSslEngineOptions, setKeyCertOptions, setKeyStoreOptions, setLogActivity, setOpenSslEngineOptions, setPemKeyCertOptions, setPemTrustOptions, setPfxKeyCertOptions, setPfxTrustOptions, setProxyProtocolTimeout, setProxyProtocolTimeoutUnit, setReadIdleTimeout, setReceiveBufferSize, setRegisterWriteHandler, setReuseAddress, setReusePort, setSendBufferSize, setSni, setSoLinger, setSslEngineOptions, setSslHandshakeTimeout, setSslHandshakeTimeoutUnit, setTcpCork, setTcpFastOpen, setTcpKeepAlive, setTcpNoDelay, setTcpQuickAck, setTrafficClass, setTrustOptions, setTrustStoreOptions, setUseAlpn, setUseProxyProtocol, setWriteIdleTimeoutgetCrlPaths, getCrlValues, getEnabledCipherSuites, getEnabledSecureTransportProtocols, getIdleTimeout, getIdleTimeoutUnit, getJdkSslEngineOptions, getKeyCertOptions, getKeyStoreOptions, getOpenSslEngineOptions, getPemKeyCertOptions, getPemTrustOptions, getPfxKeyCertOptions, getPfxTrustOptions, getReadIdleTimeout, getSoLinger, getSslEngineOptions, getSslHandshakeTimeout, getSslHandshakeTimeoutUnit, getSslOptions, getTcpUserTimeout, getTrustOptions, getTrustStoreOptions, getWriteIdleTimeout, isSsl, isTcpCork, isTcpFastOpen, isTcpKeepAlive, isTcpNoDelay, isTcpQuickAck, isUseAlpn, setTcpUserTimeoutgetActivityLogDataFormat, getLogActivity, getReceiveBufferSize, getSendBufferSize, getTrafficClass, isReuseAddress, isReusePortpublic static final int DEFAULT_MAX_HEADER_LENGTH
public static final int DEFAULT_MAX_HEADERS
public static final int DEFAULT_MAX_BODY_LENGTH
public static final int DEFAULT_MAX_FRAME_IN_TRANSACTION
public static final int DEFAULT_TRANSACTION_CHUNK_SIZE
public static final int DEFAULT_MAX_SUBSCRIPTIONS_BY_CLIENT
public static final String DEFAULT_WEBSOCKET_PATH
public StompServerOptions()
public StompServerOptions(StompServerOptions other)
other - The other StompServerOptions to copy when creating thispublic StompServerOptions(JsonObject json)
JsonObject.json - the JsonObject to create it frompublic JsonObject toJson()
NetServerOptionstoJson in class NetServerOptionspublic int getMaxBodyLength()
public StompServerOptions setMaxBodyLength(int maxBodyLength)
maxBodyLength - the length in bytes.StompServerOptionspublic int getMaxHeaderLength()
public StompServerOptions setMaxHeaderLength(int maxHeaderLength)
maxHeaderLength - the max length of headersStompServerOptionspublic int getMaxHeaders()
public StompServerOptions setMaxHeaders(int maxHeaders)
maxHeaders - the number of headersStompServerOptionspublic List<String> getSupportedVersions()
"1.2", "1.1", "1.0".public StompServerOptions setSupportedVersions(List<String> supportedVersions)
supportedVersions - the set of supported versions.StompServerOptionspublic boolean isSecured()
AuthenticationProvider handler.public StompServerOptions setSecured(boolean secured)
AuthenticationProvider handler.secured - whether or not the option should be enabled.StompServerOptionspublic boolean isSendErrorOnNoSubscriptions()
public StompServerOptions setSendErrorOnNoSubscriptions(boolean sendErrorOnNoSubscriptions)
sendErrorOnNoSubscriptions - whether or not the option should be enabled.StompServerOptionspublic int getTimeFactor()
public StompServerOptions setTimeFactor(int timeFactor)
timeFactor - the time factorStompServerOptionspublic StompServerOptions setSsl(boolean ssl)
TCPSSLOptionssetSsl in class NetServerOptionsssl - true if enabledpublic StompServerOptions setPort(int port)
setPort in class NetServerOptionsport - the port number, -1 to disable the TCP server.StompServerOptions.public int getPort()
getPort in class NetServerOptionspublic StompServerOptions setHost(String host)
NetServerOptionssetHost in class NetServerOptionshost - the hostpublic JsonObject getHeartbeat()
x: 1000, y: 1000.Frame.Heartbeatpublic StompServerOptions setHeartbeat(JsonObject heartbeat)
heartbeat - the heartbeat configurationStompServerOptionsFrame.Heartbeatpublic int getMaxFrameInTransaction()
ERROR frame and is disconnected.public StompServerOptions setMaxFrameInTransaction(int maxFrameInTransaction)
ERROR frame and is disconnected. The default
is 1000.maxFrameInTransaction - the max number of frameStompServerOptionspublic int getTransactionChunkSize()
public StompServerOptions setTransactionChunkSize(int transactionChunkSize)
transactionChunkSize - the size, must be strictly positiveStompServerOptionspublic int getMaxSubscriptionsByClient()
public StompServerOptions setMaxSubscriptionsByClient(int maxSubscriptionsByClient)
maxSubscriptionsByClient - the max number of subscriptionsStompServerOptionspublic boolean isWebsocketBridge()
true, the Stomp server provides a
io.vertx.core.Handler to read and write from the web socket. This
Handler must be passed to HttpServer.webSocketHandler(Handler).false by default.public StompServerOptions setWebsocketBridge(boolean websocketBridge)
websocketBridge - whether or not the web socket bridge should be enabled.StompServerOptionspublic String getWebsocketPath()
DEFAULT_WEBSOCKET_PATH. The returned String is not a prefix but an exact match.public StompServerOptions setWebsocketPath(String websocketPath)
websocketPath - the path, must not be null.StompServerOptionspublic boolean isTrailingLine()
public StompServerOptions setTrailingLine(boolean trailingLine)
trailingLine - true to add an empty line, false otherwiseStompServerOptionsCopyright © 2023 Eclipse. All rights reserved.