Annotation Interface EnablePool


The EnablePool annotation configures a Spring Configuration annotated class with a "named" GemFire client Pool bean in the application context. This annotation is used in conjunction with the ClientCacheApplication annotation to add an additional Pool to a GemFire cache client application configured with Spring (Data GemFire). To add more than 1 Pool to your application, this annotation can be nested in the EnablePools annotation.
Since:
1.9.0
See Also:
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static @interface 
     
    static @interface 
     
  • Required Element Summary

    Required Elements
    Modifier and Type
    Required Element
    Description
    Specifies the name of the client Pool in Pivotal GemFire/Apache Geode, which is also used as the name of the bean registered in the Spring container as well as the name used in the resolution of Pool properties from application.properties (e.g.
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    int
    Configures the free connection timeout for this pool.
    long
    Configures the amount of time a connection can be idle before expiring the connection.
    int
    Configures the load conditioning interval for this pool.
    Configures the GemFire Locators to which this cache client will connect.
    A String containing a comma-delimited list of hosts and ports defining the connection endpoints of GemFire Locators in the cluster.
    int
    Configures the max number of client to server connections that the pool will create.
    int
    Configures the max number of client to server connections that the pool will create per server.
    int
    Configures the minimum number of connections to keep available at all times.
    int
    Configures the minimum number of connections to keep available per server at all times.
    boolean
    If set to true then the created pool can be used by multiple users.
    long
    Configures how often to ping servers to verify that they are still alive.
    boolean
    By default prSingleHopEnabled is true in which case the client is aware of the location of partitions on servers hosting Regions with DataPolicy.PARTITION.
    int
    Configures the number of milliseconds to wait for a response from a server before timing out the operation and trying another server (if any are available).
    int
    Configures the number of times to retry a request after timeout/exception.
    int
    Configures the server connection timeout for this Pool.
    Configures the group that all servers in which this pool connects to must belong to.
    Configures the GemFire CacheServers to which this cache client will connect.
    A String containing a comma-delimited list of hosts and ports defining the connection endpoints of GemFire Servers in the cluster.
    int
    Configures the socket buffer size for each connection made in this pool.
    int
    Configures the socket connect timeout for this "named" Pool.
    Configures the SocketFactory bean name used by this Pool to create connections to both Locators (if configured using locators()) and Servers.
    int
    Configures how often to send client statistics to the server.
    int
    Configures the interval in milliseconds to wait before sending acknowledgements to the cache server for events received from the server subscriptions.
    boolean
    If set to true then the created pool will have server-to-client subscriptions enabled.
    int
    Configures the messageTrackingTimeout attribute which is the time-to-live period, in milliseconds, for subscription events the client has received from the server.
    int
    Configures the redundancy level for this pools server-to-client subscriptions.
  • Element Details

    • name

      String name
      Specifies the name of the client Pool in Pivotal GemFire/Apache Geode, which is also used as the name of the bean registered in the Spring container as well as the name used in the resolution of Pool properties from application.properties (e.g. spring.data.gemfire.pool.<poolName>.max-connections), that are specific to this Pool.
    • freeConnectionTimeout

      int freeConnectionTimeout
      Configures the free connection timeout for this pool. Defaults to PoolFactory.DEFAULT_FREE_CONNECTION_TIMEOUT. Use either the spring.data.gemfire.pool.<poolName>.free-connection-timeout property or the spring.data.gemfire.pool.free-connection-timeout property in application.properties.
      Default:
      10000
    • idleTimeout

      long idleTimeout
      Configures the amount of time a connection can be idle before expiring the connection. Defaults to PoolFactory.DEFAULT_IDLE_TIMEOUT. Use either the spring.data.gemfire.pool.<poolName>.idle-timeout property or the spring.data.gemfire.pool.idle-timeout property in application.properties.
      Default:
      120000L
    • loadConditioningInterval

      int loadConditioningInterval
      Configures the load conditioning interval for this pool. Defaults to PoolFactory.DEFAULT_LOAD_CONDITIONING_INTERVAL. Use either the spring.data.gemfire.pool.<poolName>.load-conditioning-interval property or the spring.data.gemfire.pool.load-conditioning-interval property in application.properties.
      Default:
      300000
    • locators

      EnablePool.Locator[] locators
      Configures the GemFire Locators to which this cache client will connect. Use either the spring.data.gemfire.pool.<poolName>.locators property or the spring.data.gemfire.pool.locators property in application.properties.
      Default:
      {}
    • locatorsString

      String locatorsString
      A String containing a comma-delimited list of hosts and ports defining the connection endpoints of GemFire Locators in the cluster. The String must be formatted as: 'host1[port], host2[port], ..., hostN[port]'. Use either the spring.data.gemfire.pool.<poolName>.locators property or the spring.data.gemfire.pool.locators property in application.properties.
      Default:
      ""
    • maxConnections

      int maxConnections
      Configures the max number of client to server connections that the pool will create. Cannot be used with maxConnectionsPerServer set. Defaults to PoolFactory.DEFAULT_MAX_CONNECTIONS. Use either the spring.data.gemfire.pool.<poolName>.max-connections property or the spring.data.gemfire.pool.max-connections property in application.properties.
      Default:
      -1
    • minConnections

      int minConnections
      Configures the minimum number of connections to keep available at all times. Cannot be used with minConnectionsPerServer set. Defaults to PoolFactory.DEFAULT_MIN_CONNECTIONS. Use either the spring.data.gemfire.pool.<poolName>.min-connections property or the spring.data.gemfire.pool.min-connections property in application.properties.
      Default:
      1
    • maxConnectionsPerServer

      int maxConnectionsPerServer
      Configures the max number of client to server connections that the pool will create per server. Cannot be used with maxConnections set. Defaults to PoolFactory.DEFAULT_MAX_CONNECTIONS_PER_SERVER. Use either the spring.data.gemfire.pool.<poolName>.max-connections-per-server property or the spring.data.gemfire.pool.max-connections-per-server property in application.properties.
      Default:
      -1
    • minConnectionsPerServer

      int minConnectionsPerServer
      Configures the minimum number of connections to keep available per server at all times. Cannot be used with minConnections set. Defaults to PoolFactory.DEFAULT_MIN_CONNECTIONS_PER_SERVER. Use either the spring.data.gemfire.pool.<poolName>.min-connections-per-server property or the spring.data.gemfire.pool.min-connections-per-server property in application.properties.
      Default:
      1
    • multiUserAuthentication

      boolean multiUserAuthentication
      If set to true then the created pool can be used by multiple users. Defaults to PoolFactory.DEFAULT_MULTIUSER_AUTHENTICATION. Use either the spring.data.gemfire.pool.<poolName>.multi-user-authentication property or the spring.data.gemfire.pool.multi-user-authentication property in application.properties.
      Default:
      false
    • pingInterval

      long pingInterval
      Configures how often to ping servers to verify that they are still alive. Defaults to PoolFactory.DEFAULT_PING_INTERVAL. Use either the spring.data.gemfire.pool.<poolName>.ping-interval property or the spring.data.gemfire.pool.ping-interval property in application.properties.
      Default:
      10000L
    • prSingleHopEnabled

      boolean prSingleHopEnabled
      By default prSingleHopEnabled is true in which case the client is aware of the location of partitions on servers hosting Regions with DataPolicy.PARTITION. Defaults to PoolFactory.DEFAULT_PR_SINGLE_HOP_ENABLED. Use either the spring.data.gemfire.pool.<poolName>.pr-single-hop-enabled property or the spring.data.gemfire.pool.pr-single-hop-enabled property in application.properties.
      Default:
      true
    • readTimeout

      int readTimeout
      Configures the number of milliseconds to wait for a response from a server before timing out the operation and trying another server (if any are available). Defaults to PoolFactory.DEFAULT_READ_TIMEOUT. Use either the spring.data.gemfire.pool.<poolName>.read-timeout property or the spring.data.gemfire.pool.read-timeout property in application.properties.
      Default:
      10000
    • retryAttempts

      int retryAttempts
      Configures the number of times to retry a request after timeout/exception. Defaults to PoolFactory.DEFAULT_RETRY_ATTEMPTS. Use either the spring.data.gemfire.pool.<poolName>.retry-attempts property or the spring.data.gemfire.pool.retry-attempts property in application.properties.
      Default:
      -1
    • serverConnectionTimeout

      int serverConnectionTimeout
      Configures the server connection timeout for this Pool. If the pool has a max connections setting, operations will block if there is no free connection for a specific server. The server connection timeout specifies how long those operations will block waiting for a free connection for a specific server before receiving an AllConnectionsInUseException. If max connections is not set this setting has no effect. This setting differs from freeConnectionTimeout(), which sets the wait time for any server connection in the pool, whereas this setting sets the wait time for a free connection to a specific server. Defaults to PoolFactory.DEFAULT_SERVER_CONNECTION_TIMEOUT. Use either the spring.data.gemfire.pool.<poolName>.server-connection-timeout property or the spring.data.gemfire.pool.server-connection-timeout property in application.properties.
      Default:
      0
    • serverGroup

      String serverGroup
      Configures the group that all servers in which this pool connects to must belong to. Defaults to PoolFactory.DEFAULT_SERVER_GROUP. Use either the spring.data.gemfire.pool.<poolName>.server-group property or the spring.data.gemfire.pool.server-group property in application.properties.
      Default:
      ""
    • servers

      Configures the GemFire CacheServers to which this cache client will connect. Use either the spring.data.gemfire.pool.<poolName>.servers property or the spring.data.gemfire.pool.servers property in application.properties.
      Default:
      {}
    • serversString

      String serversString
      A String containing a comma-delimited list of hosts and ports defining the connection endpoints of GemFire Servers in the cluster. The String must be formatted as: 'host1[port], host2[port], ..., hostN[port]'. Use either the spring.data.gemfire.pool.<poolName>.servers property or the spring.data.gemfire.pool.servers property in application.properties.
      Default:
      ""
    • socketBufferSize

      int socketBufferSize
      Configures the socket buffer size for each connection made in this pool. Defaults to PoolFactory.DEFAULT_SOCKET_BUFFER_SIZE. Use either the spring.data.gemfire.pool.<poolName>.socket-buffer-size property or the spring.data.gemfire.pool.socket-buffer-size property in application.properties.
      Default:
      32768
    • socketConnectTimeout

      int socketConnectTimeout
      Configures the socket connect timeout for this "named" Pool. The number of milliseconds specified as socket timeout when the client connects to the servers/locators. A timeout of zero is interpreted as an infinite timeout. The connection will then block until established or an error occurs. Defaults to PoolFactory.DEFAULT_SOCKET_CONNECT_TIMEOUT. Use either the spring.data.gemfire.pool.<poolName>.socket-connect-timeout property or the spring.data.gemfire.pool.socket-connect-timeout property in application.properties.
      Default:
      59000
    • socketFactoryBeanName

      String socketFactoryBeanName
      Configures the SocketFactory bean name used by this Pool to create connections to both Locators (if configured using locators()) and Servers. Defaults to unset. Use either the spring.data.gemfire.pool.<poolName>.socket-factory-bean-name property or the spring.data.gemfire.pool.socket-factory-bean-name property in application.properties.
      Default:
      ""
    • statisticInterval

      int statisticInterval
      Configures how often to send client statistics to the server. Defaults to PoolFactory.DEFAULT_STATISTIC_INTERVAL. Use either the spring.data.gemfire.pool.<poolName>.statistic-interval property or the spring.data.gemfire.pool.statistic-interval property in application.properties.
      Default:
      -1
    • subscriptionAckInterval

      int subscriptionAckInterval
      Configures the interval in milliseconds to wait before sending acknowledgements to the cache server for events received from the server subscriptions. Defaults to PoolFactory.DEFAULT_SUBSCRIPTION_ACK_INTERVAL. Use either the spring.data.gemfire.pool.<poolName>.subscription-ack-interval property or the spring.data.gemfire.pool.subscription-ack-interval property in application.properties.
      Default:
      100
    • subscriptionEnabled

      boolean subscriptionEnabled
      If set to true then the created pool will have server-to-client subscriptions enabled. Defaults to PoolFactory.DEFAULT_SUBSCRIPTION_ENABLED. Use either the spring.data.gemfire.pool.<poolName>.subscription-enabled property or the spring.data.gemfire.pool.subscription-enabled property in application.properties.
      Default:
      false
    • subscriptionMessageTrackingTimeout

      int subscriptionMessageTrackingTimeout
      Configures the messageTrackingTimeout attribute which is the time-to-live period, in milliseconds, for subscription events the client has received from the server. Defaults to PoolFactory.DEFAULT_SUBSCRIPTION_MESSAGE_TRACKING_TIMEOUT. Use either the spring.data.gemfire.pool.<poolName>.subscription-message-tracking-timeout property or the spring.data.gemfire.pool.subscription-message-tracking-timeout property in application.properties.
      Default:
      900000
    • subscriptionRedundancy

      int subscriptionRedundancy
      Configures the redundancy level for this pools server-to-client subscriptions. Defaults to PoolFactory.DEFAULT_SUBSCRIPTION_REDUNDANCY. Use either the spring.data.gemfire.pool.<poolName>.subscription-redundancy property or the spring.data.gemfire.pool.subscription-redundancy property in application.properties.
      Default:
      0