Class CacheConnectionOptions


  • public class CacheConnectionOptions
    extends java.lang.Object
    Instance of this class can be used to define the parameters at the time of client connection with the cache.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object clone()
      Creates a new object that is a copy of the current instance.
      java.lang.String getAppName()
      Gets the appication name.If different client applications are connected to server and because of any issue which results in connection failure with server, after the client again establishes connection AppName is used to identify these different client applications.
      java.lang.String getClientBindIP()
      Gets the IP for the client to be binded with.
      ClientCacheSyncMode getClientCacheMode()
      Gets ClientCacheSyncMode to specify how the Client cache is synchronized with the cluster caches through events.
      TimeSpan getClientRequestTimeOut()
      Clients operation timeout specified in seconds.
      java.lang.Integer getCommandRetries()
      If client application sends request to server for any operation and a response is not received, then the number of retries it will make until it gets response is defined here.
      TimeSpan getCommandRetryInterval()
      In case if client app doesn’t get response against some operation call on server, the command retry interval defines the waiting period before the next attempt to send the operation the server is made.
      java.lang.Integer getConnectionRetries()
      Number of tries to re-establish a broken connection between client and server.
      TimeSpan getConnectionTimeout()
      Client's connection timeout specified in seconds.
      java.lang.String getDefaultReadThruProvider()
      Gets the name of the default ReadThruProvider.
      java.lang.String getDefaultWriteThruProvider()
      Gets the name of default WriteThruProvider.
      java.lang.Boolean getEnableClientLogs()
      Gets the flag that specifies whether to create client logs or not.
      java.lang.Boolean getEnableKeepAlive()
      Gets the keep alive flag.
      IsolationLevel getIsolationMode()
      Gets the Isolation level of the cache.
      TimeSpan getKeepAliveInterval()
      Gets the KeepAliveInterval, which will be in effect if the EnabledKeepAlive is set 'true' or is specified 'true' from the client configuration.
      java.lang.Boolean getLoadBalance()
      When this flag is set, client tries to connect to the optimum server in terms of number of connected clients.
      LogLevel getLogLevel()
      Gets the LogLevel either as Info, Error or Debug.
      TimeSpan getRetryConnectionDelay()
      The time after which client will try to reconnect to the server.
      TimeSpan getRetryInterval()
      Time in seconds to wait between two connection retries.
      java.util.List<ServerInfo> getServerList()
      Gets the list of ServerInfo in the cache.
      Credentials getUserCredentials()
      Gets Credentials for the authentication of connection with the cache.
      void setAppName​(java.lang.String value)
      Sets the appication name.If different client applications are connected to server and because of any issue which results in connection failure with server, after the client again establishes connection AppName is used to identify these different client applications.
      void setClientBindIP​(java.lang.String value)
      Sets the IP for the client to be binded with.
      void setClientCacheMode​(ClientCacheSyncMode value)
      Sets ClientCacheSyncMode to specify how the Client cache is synchronized with the cluster caches through events.
      void setClientRequestTimeOut​(TimeSpan value)
      Clients operation timeout specified in seconds.
      void setCommandRetries​(java.lang.Integer value)
      If client application sends request to server for any operation and a response is not received, then the number of retries it will make until it gets response is defined here.
      void setCommandRetryInterval​(TimeSpan value)
      In case if client app doesn’t get response against some operation call on server, the command retry interval defines the waiting period before the next attempt to send the operation the server is made.
      void setConnectionRetries​(java.lang.Integer value)
      Number of tries to re-establish a broken connection between client and server.
      void setConnectionTimeout​(TimeSpan value)
      Client's connection timeout specified in seconds.
      void setDefaultReadThruProvider​(java.lang.String value)
      Sets the name of the default ReadThruProvider.
      void setDefaultWriteThruProvider​(java.lang.String value)
      Sets the name of default WriteThruProvider.
      void setEnableClientLogs​(java.lang.Boolean value)
      Sets the flag that specifies whether to create client logs or not.
      void setEnableKeepAlive​(java.lang.Boolean value)
      Sets the keep alive flag.
      void setIsolationLevel​(IsolationLevel value)
      Sets the isolation level of the cache.
      void setKeepAliveInterval​(TimeSpan value)
      Sets the KeepAliveInterval, which will be in effect if the EnabledKeepAlive is set 'true' or is specified 'true' from the client configuration.
      void setLoadBalance​(java.lang.Boolean value)
      When this flag is set, client tries to connect to the optimum server in terms of number of connected clients.
      void setLogLevel​(LogLevel value)
      Sets the LogLevel either as Info, Error or Debug.
      void setRetryConnectionDelay​(TimeSpan value)
      The time after which client will try to reconnect to the server.
      void setRetryInterval​(TimeSpan value)
      Time in seconds to wait between two connection retries.
      void setServerList​(java.util.List<ServerInfo> value)
      Sets the list of ServerInfo in the cache.
      void setUserCredentials​(Credentials value)
      Gets Credentials for the authentication of connection with the cache.
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • CacheConnectionOptions

        public CacheConnectionOptions()
    • Method Detail

      • getServerList

        public java.util.List<ServerInfo> getServerList()
        Gets the list of ServerInfo in the cache.
        Returns:
        The list of Server info's.
      • setServerList

        public void setServerList​(java.util.List<ServerInfo> value)
        Sets the list of ServerInfo in the cache.
        Parameters:
        value - The list of Server info's.
      • getIsolationMode

        public IsolationLevel getIsolationMode()
        Gets the Isolation level of the cache.
        Returns:
        The isolation level of the cache.
      • setIsolationLevel

        public void setIsolationLevel​(IsolationLevel value)
        Sets the isolation level of the cache.
        Parameters:
        value - The isolation level of the cache.
      • getDefaultReadThruProvider

        public java.lang.String getDefaultReadThruProvider()
        Gets the name of the default ReadThruProvider.
        Returns:
        The name of the default ReadThruProvider.
      • setDefaultReadThruProvider

        public void setDefaultReadThruProvider​(java.lang.String value)
        Sets the name of the default ReadThruProvider.
        Parameters:
        value - The name of the default ReadThruProvider.
      • getDefaultWriteThruProvider

        public java.lang.String getDefaultWriteThruProvider()
        Gets the name of default WriteThruProvider.
        Returns:
        The name of default WriteThruProvider.
      • setDefaultWriteThruProvider

        public void setDefaultWriteThruProvider​(java.lang.String value)
        Sets the name of default WriteThruProvider.
        Parameters:
        value - The name of default WriteThruProvider.
      • getClientBindIP

        public java.lang.String getClientBindIP()
        Gets the IP for the client to be binded with.
        Returns:
        The IP for the client to be binded with.
      • setClientBindIP

        public void setClientBindIP​(java.lang.String value)
        Sets the IP for the client to be binded with.
        Parameters:
        value - The IP for the client to be binded with.
      • getAppName

        public java.lang.String getAppName()
        Gets the appication name.If different client applications are connected to server and because of any issue which results in connection failure with server, after the client again establishes connection AppName is used to identify these different client applications.
        Returns:
        The application name.
      • setAppName

        public void setAppName​(java.lang.String value)
        Sets the appication name.If different client applications are connected to server and because of any issue which results in connection failure with server, after the client again establishes connection AppName is used to identify these different client applications.
        Parameters:
        value - The application name.
      • getLoadBalance

        public java.lang.Boolean getLoadBalance()
        When this flag is set, client tries to connect to the optimum server in terms of number of connected clients.
        Returns:
        True if loadBalancing enabled otherwise false.
      • setLoadBalance

        public void setLoadBalance​(java.lang.Boolean value)
        When this flag is set, client tries to connect to the optimum server in terms of number of connected clients.
        Parameters:
        value - The boolean value indicating whether to set LoadBalancing true or false.
      • getClientRequestTimeOut

        public TimeSpan getClientRequestTimeOut()
        Clients operation timeout specified in seconds. Clients wait for the response from the server for this time. If the response is not received within this time, the operation is not successful.
        Returns:
        The request timeout associated with connection options.
      • setClientRequestTimeOut

        public void setClientRequestTimeOut​(TimeSpan value)
        Clients operation timeout specified in seconds. Clients wait for the response from the server for this time. If the response is not received within this time, the operation is not successful.
        Parameters:
        value - The request timeout to be associated with connection options.
      • getConnectionTimeout

        public TimeSpan getConnectionTimeout()
        Client's connection timeout specified in seconds.
        Returns:
        The client connecton timeout in form of a TimeSpan.
      • setConnectionTimeout

        public void setConnectionTimeout​(TimeSpan value)
        Client's connection timeout specified in seconds.
        Parameters:
        value - The client connecton timeout in form of a TimeSpan.
      • getConnectionRetries

        public java.lang.Integer getConnectionRetries()
        Number of tries to re-establish a broken connection between client and server.
        Returns:
        An integer indicating the number of retries.
      • setConnectionRetries

        public void setConnectionRetries​(java.lang.Integer value)
        Number of tries to re-establish a broken connection between client and server.
        Parameters:
        value - An integer indicating the number of retries.
      • getRetryInterval

        public TimeSpan getRetryInterval()
        Time in seconds to wait between two connection retries.
        Returns:
        The retry interval in form of TimeSpan.
      • setRetryInterval

        public void setRetryInterval​(TimeSpan value)
        Time in seconds to wait between two connection retries.
        Parameters:
        value - The retry interval in form of TimeSpan.
      • getRetryConnectionDelay

        public TimeSpan getRetryConnectionDelay()
        The time after which client will try to reconnect to the server.
        Returns:
        The retry connection delay in form of TimeSpan.
      • setRetryConnectionDelay

        public void setRetryConnectionDelay​(TimeSpan value)
        The time after which client will try to reconnect to the server.
        Parameters:
        value - The retry connection delay in form of TimeSpan.
      • getClientCacheMode

        public ClientCacheSyncMode getClientCacheMode()
        Gets ClientCacheSyncMode to specify how the Client cache is synchronized with the cluster caches through events.
        Returns:
        The client cache sync mode associated with connection options.
      • setClientCacheMode

        public void setClientCacheMode​(ClientCacheSyncMode value)
        Sets ClientCacheSyncMode to specify how the Client cache is synchronized with the cluster caches through events.
        Parameters:
        value - The client cache sync mode to be associated with connection options.
      • getCommandRetries

        public java.lang.Integer getCommandRetries()
        If client application sends request to server for any operation and a response is not received, then the number of retries it will make until it gets response is defined here.
        Returns:
        An integer indicating the number of command retries.
      • setCommandRetries

        public void setCommandRetries​(java.lang.Integer value)
        If client application sends request to server for any operation and a response is not received, then the number of retries it will make until it gets response is defined here.
        Parameters:
        value - An integer indicating the number of command retries.
      • getCommandRetryInterval

        public TimeSpan getCommandRetryInterval()
        In case if client app doesn’t get response against some operation call on server, the command retry interval defines the waiting period before the next attempt to send the operation the server is made. Type integer which defines seconds.
        Returns:
        The command retry interval in form of TimeSpan.
      • setCommandRetryInterval

        public void setCommandRetryInterval​(TimeSpan value)
        In case if client app doesn’t get response against some operation call on server, the command retry interval defines the waiting period before the next attempt to send the operation the server is made. Type integer which defines seconds.
        Parameters:
        value - The command retry interval in form of TimeSpan.
      • getEnableKeepAlive

        public java.lang.Boolean getEnableKeepAlive()
        Gets the keep alive flag.
        Returns:
        True if keep alive enabled otherwise false.
      • setEnableKeepAlive

        public void setEnableKeepAlive​(java.lang.Boolean value)
        Sets the keep alive flag.
        Parameters:
        value - A boolean value that specifies whether to enable keep alive or not.
      • getKeepAliveInterval

        public TimeSpan getKeepAliveInterval()
        Gets the KeepAliveInterval, which will be in effect if the EnabledKeepAlive is set 'true' or is specified 'true' from the client configuration.
        Returns:
        The keep alive interval in form of TimeSpan.
      • setKeepAliveInterval

        public void setKeepAliveInterval​(TimeSpan value)
        Sets the KeepAliveInterval, which will be in effect if the EnabledKeepAlive is set 'true' or is specified 'true' from the client configuration.
        Parameters:
        value - The keep alive interval in form of TimeSpan.
      • getUserCredentials

        public Credentials getUserCredentials()
        Gets Credentials for the authentication of connection with the cache. This information is required when the security is enabled.
        Returns:
        The credentials for the authentication of cache connection.
      • setUserCredentials

        public void setUserCredentials​(Credentials value)
        Gets Credentials for the authentication of connection with the cache. This information is required when the security is enabled.
        Parameters:
        value - The credentials for the authentication of cache connection.
      • getLogLevel

        public LogLevel getLogLevel()
        Gets the LogLevel either as Info, Error or Debug.
        Returns:
        The log level associated with connection options.
      • setLogLevel

        public void setLogLevel​(LogLevel value)
        Sets the LogLevel either as Info, Error or Debug.
        Parameters:
        value - The log level to be associated with connection options.
      • getEnableClientLogs

        public java.lang.Boolean getEnableClientLogs()
        Gets the flag that specifies whether to create client logs or not.
        Returns:
        True if client logs are enabled otherwise false.
      • setEnableClientLogs

        public void setEnableClientLogs​(java.lang.Boolean value)
        Sets the flag that specifies whether to create client logs or not.
        Parameters:
        value - The boolean value that specifies whether client logs are enabled or not.
      • clone

        public java.lang.Object clone()
        Creates a new object that is a copy of the current instance.
        Overrides:
        clone in class java.lang.Object
        Returns:
        The cloned object.