Interface ClusteredDatasetManagerBuilder


public interface ClusteredDatasetManagerBuilder
A ClusteredDatasetManagerBuilder allows configuration of the interaction with a cluster.
  • Field Details

    • DEFAULT_CONNECTION_TIMEOUT_MS

      static final long DEFAULT_CONNECTION_TIMEOUT_MS
      The default connection timeout in milliseconds.
      See Also:
    • DEFAULT_RECONNECT_TIMEOUT_MS

      static final long DEFAULT_RECONNECT_TIMEOUT_MS
      The default reconnect timeout in milliseconds. A value of zero indicates no timeout.
      See Also:
  • Method Details

    • build

      Creates the DatasetManager that has been configured using this ClusteredDatasetManagerBuilder
      Returns:
      a DatasetManager instance
      Throws:
      StoreException - if the creation of the DatasetManager fails
    • withConnectionTimeout

      ClusteredDatasetManagerBuilder withConnectionTimeout(long timeout, TimeUnit unit)
      Configures this DatasetManager to use a specific connection timeout.

      The default timeout is given by DEFAULT_CONNECTION_TIMEOUT_MS.

      Parameters:
      timeout - connection timeout
      unit - connection timeout unit
      Returns:
      a ClusteredDatasetManagerBuilder to allow further configuration
    • withReconnectTimeout

      ClusteredDatasetManagerBuilder withReconnectTimeout(long timeout, TimeUnit unit)
      Configures this DatasetManager to use the specific reconnect timeout. This is used, instead of the withConnectionTimeout(long, java.util.concurrent.TimeUnit) value when attempting to reconnect to a server following discovery of a dropped connection.

      The default timeout is given by DEFAULT_RECONNECT_TIMEOUT_MS. A value of zero indicates reconnection attempts do not time out.

      Parameters:
      timeout - reconnect timeout
      unit - reconnect timeout unit
      Returns:
      a ClusteredDatasetManagerBuilder to allow further configuration
    • withConnectionProperties

      ClusteredDatasetManagerBuilder withConnectionProperties(Properties properties)
      Sets Properties for this clustered client's connection.
      Parameters:
      properties - the clustered client's connection properties
      Returns:
      a ClusteredDatasetManagerBuilder to allow further configuration
    • withClientAlias

      ClusteredDatasetManagerBuilder withClientAlias(String alias)
      Sets an alias to identify this clustered client. By default, one is randomly generated.
      Parameters:
      alias - the clustered client's alias
      Returns:
      a ClusteredDatasetManagerBuilder to allow further configuration
    • withClientTags

      default ClusteredDatasetManagerBuilder withClientTags(String... tags)
      Sets some tags to categorize this clustered client. Replaces any previously set tags.
      Parameters:
      tags - a list of tags
      Returns:
      a ClusteredDatasetManagerBuilder to allow further configuration
    • withClientTags

      ClusteredDatasetManagerBuilder withClientTags(Set<String> tags)
      Sets some tags to categorize this clustered client. Replaces any previously set tags.
      Parameters:
      tags - a list of tags
      Returns:
      a ClusteredDatasetManagerBuilder to allow further configuration