Class ClientSettings

    • Constructor Detail

      • ClientSettings

        public ClientSettings​(boolean haModeOn)
        Creates a ClientSettings that uses StreamBase default values for all settings
        Parameters:
        haModeOn - true to enable High Availability features when connecting to more than one server, false otherwise for single-server connections
        Since:
        7.1
    • Method Detail

      • getOpenTimeoutMS

        public long getOpenTimeoutMS()
        OpenTimeoutMS is used as a timeout value for opening a binary) connection between the client and server.
        Returns:
        the openTimeout in milliseconds
      • setOpenTimeoutMS

        public ClientSettings setOpenTimeoutMS​(long openTimeoutMS)
        OpenTimeoutMS is used as a timeout value for opening a binary connection between the client and server.
        Parameters:
        openTimeoutMS - new value for the openTimeout in milliseconds
        Returns:
        this ClientSettings object
      • getWriteTimeoutMS

        public long getWriteTimeoutMS()
        WriteTimeoutMS is used as a timeout for write operations in a binary connection between the client and server.
        Returns:
        writeTimeout in milliseconds
      • setWriteTimeoutMS

        public ClientSettings setWriteTimeoutMS​(long writeTimeoutMS)
        WriteTimeoutMS is used as a timeout for write operations in a binary connection between the client and server.
        Parameters:
        writeTimeoutMS - new value for the writeTimeout in milliseconds
        Returns:
        this ClientSettings object
      • getXmlRpcTimeoutMS

        public long getXmlRpcTimeoutMS()
        XmlrpcTimeoutMS is used as a timeout for XMLRPC requests to the server.
        Returns:
        xmlrpcTimeout in milliseconds
      • setXmlRpcTimeoutMS

        public ClientSettings setXmlRpcTimeoutMS​(long xmlrpcTimeoutMS)
        XmlrpcTimeoutMS is used as a timeout for XMLRPC requests to the server.
        Parameters:
        xmlrpcTimeoutMS - new value for xmlrpcTimeout in milliseconds
        Returns:
        this ClientSettings object
      • getExitStatusTimeoutMS

        public long getExitStatusTimeoutMS()
        ExitStatusTimeoutMS is used as a timeout for how long the client should wait to get the client's exit status from the server.
        Returns:
        exitStatusTimeout in milliseconds
      • setExitStatusTimeoutMS

        public ClientSettings setExitStatusTimeoutMS​(long exitStatusTimeoutMS)
        ExitStatusTimeoutMS is used as a timeout for how long the client should wait to get the client's exit status from the server.
        Parameters:
        exitStatusTimeoutMS - new value for exitStatusTimeout in milliseconds
        Returns:
        this ClientSettings object
      • getQuiescentTimeoutMS

        public long getQuiescentTimeoutMS()
        QuiescentTimeoutMS is a timeout value that is used to determine how long a client's binary connection will wait for a heartbeat message from a server. The client will close() if QuiescentTimeoutMS has elasped.
        Returns:
        quiescentTimeout in milliseconds
      • setQuiescentTimeoutMS

        public ClientSettings setQuiescentTimeoutMS​(long quiescentTimeoutMS)
        QuiescentTimeoutMS is a timeout value that is used to determine how long a client's binary) connection will wait for a heartbeat message from a server. The client will close() if QuiescentTimeoutMS has elasped.
        Parameters:
        quiescentTimeoutMS - new value for quiescentTimeout in milliseconds
        Returns:
        this ClientSettings object
      • getReconnectSleepMS

        public long getReconnectSleepMS()
        How long will a client wait between reconnect attempts when in HA mode
        Returns:
        reconnectSleep in milliseconds
      • setReconnectSleepMS

        public ClientSettings setReconnectSleepMS​(long reconnectSleepMS)
        How long will a client wait between reconnect attempts when in HA mode
        Parameters:
        reconnectSleepMS - new value for reconnectSleep in milliseconds
        Returns:
        this ClientSettings object
      • getMaxTuplesInDequeueQueue

        public int getMaxTuplesInDequeueQueue()
        The dequeue thread stores tuples to be dequeued by a client in a queue. This is the max size of the queue (in tuples) before the dequeue thread blocks.
        Returns:
        max number of tuples to store in the dequeue thread's queue
      • setMaxTuplesInDequeueQueue

        public ClientSettings setMaxTuplesInDequeueQueue​(int maxTuplesInDequeueQueue)
        The dequeue thread stores tuples to be dequeued by a client in a queue. This is the max size of the queue (in tuples) before the dequeue thread blocks.
        Parameters:
        maxTuplesInDequeueQueue - new value for MaxTuplesInDequeueQueue
        Returns:
        this ClientSettings object
      • isSocketKeepAlive

        public boolean isSocketKeepAlive()
        Is SO_KEEPALIVE set
        Returns:
        is SO_KEEPALIVE set
        See Also:
        SocketOptions.SO_KEEPALIVE
      • setSocketKeepAlive

        public ClientSettings setSocketKeepAlive​(boolean socketKeepAlive)
        Set SO_KEEPALIVE
        Parameters:
        socketKeepAlive - enable/disable SO_KEEPALIVE
        Returns:
        this ClientSettings object
        See Also:
        SocketOptions.SO_KEEPALIVE
      • isTcpNoDelay

        public boolean isTcpNoDelay()
        Is TCP_NODELAY set
        Returns:
        is TCP_NODELAY set
        See Also:
        SocketOptions.TCP_NODELAY
      • setTcpNoDelay

        public ClientSettings setTcpNoDelay​(boolean tcpNoDelay)
        Set TCP_NODELAY
        Parameters:
        tcpNoDelay - enable/disable TCP_NODELAY
        Returns:
        this ClientSettings object
        See Also:
        SocketOptions.TCP_NODELAY