org.infinispan.loaders.jdbc.stringbased
Class JdbcStringBasedCacheStoreConfig

java.lang.Object
  extended by org.infinispan.config.AbstractConfigurationBean
      extended by org.infinispan.config.AbstractNamedCacheConfigurationBean
          extended by org.infinispan.config.PluggableConfigurationComponent
              extended by org.infinispan.loaders.AbstractCacheStoreConfig
                  extended by org.infinispan.loaders.LockSupportCacheStoreConfig
                      extended by org.infinispan.loaders.jdbc.stringbased.JdbcStringBasedCacheStoreConfig
All Implemented Interfaces:
Serializable, Cloneable, CloneableConfigurationComponent, CacheLoaderConfig, CacheStoreConfig

public class JdbcStringBasedCacheStoreConfig
extends LockSupportCacheStoreConfig

Configuration for JdbcStringBasedCacheStore cache store.

Author:
Mircea.Markus@jboss.com
See Also:
Key2StringMapper, Serialized Form

Field Summary
 
Fields inherited from class org.infinispan.loaders.LockSupportCacheStoreConfig
DEFAULT_CONCURRENCY_LEVEL, DEFAULT_LOCK_ACQUISITION_TIMEOUT
 
Fields inherited from class org.infinispan.loaders.AbstractCacheStoreConfig
cacheLoaderClassName
 
Fields inherited from class org.infinispan.config.PluggableConfigurationComponent
properties
 
Fields inherited from class org.infinispan.config.AbstractNamedCacheConfigurationBean
cr
 
Fields inherited from class org.infinispan.config.AbstractConfigurationBean
EMPTY_PROPERTIES, log, overriddenConfigurationElements
 
Constructor Summary
JdbcStringBasedCacheStoreConfig()
           
JdbcStringBasedCacheStoreConfig(boolean manageConnectionFactory)
           
JdbcStringBasedCacheStoreConfig(ConnectionFactoryConfig connectionFactoryConfig, TableManipulation tableManipulation)
           
 
Method Summary
 int getBatchSize()
           
 ConnectionFactoryConfig getConnectionFactoryConfig()
           
 int getFetchSize()
           
 Key2StringMapper getKey2StringMapper()
           
 TableManipulation getTableManipulation()
           
 void setBatchSize(int batchSize)
           
 void setConnectionFactoryClass(String connectionFactoryClass)
           
 void setConnectionUrl(String connectionUrl)
          Jdbc connection string for connecting to the database.
 void setCreateTableOnStart(boolean createTableOnStart)
           
 void setDataColumnName(String dataColumnName)
          Sets the name of the column where the StoredEntry will be binary stored.
 void setDataColumnType(String dataColumnType)
          Sets the type of the column where data will be binary stored.
 void setDriverClass(String driverClassName)
          The name of the driver used for connecting to the database.
 void setDropTableOnExit(boolean dropTableOnExit)
           
 void setFetchSize(int fetchSize)
           
 void setIdColumnName(String idColumnName)
          Sets the name of the column where the id will be stored.
 void setIdColumnType(String idColumnType)
          sql equivalent for java's String.
 void setKey2StringMapperClass(String className)
          Name of the class implementing Key2StringMapper.
 void setPassword(String password)
          Database username's password.
 void setStringsTableName(String stringsTableName)
          Sets the name of the table where data will be stored.
 void setTableManipulation(TableManipulation tableManipulation)
           
 void setTimestampColumnName(String timestampColumnName)
          Sets the name of the column where the timestamp (Long in java) will be stored.
 void setUserName(String userName)
          Database username.
 
Methods inherited from class org.infinispan.loaders.LockSupportCacheStoreConfig
getLockAcquistionTimeout, getLockConcurrencyLevel, setLockAcquistionTimeout, setLockConcurrencyLevel
 
Methods inherited from class org.infinispan.loaders.AbstractCacheStoreConfig
clone, equals, equalsExcludingProperties, getAsyncStoreConfig, getCacheLoaderClassName, getSingletonStoreConfig, hashCode, hashCodeExcludingProperties, isFetchPersistentState, isIgnoreModifications, isPurgeOnStartup, isPurgeSynchronously, setAsyncStoreConfig, setCacheLoaderClassName, setFetchPersistentState, setIgnoreModifications, setPurgeOnStartup, setPurgeSynchronously, setSingletonStoreConfig, toString
 
Methods inherited from class org.infinispan.config.PluggableConfigurationComponent
getProperties, setProperties, setProperties
 
Methods inherited from class org.infinispan.config.AbstractNamedCacheConfigurationBean
hasComponentStarted
 
Methods inherited from class org.infinispan.config.AbstractConfigurationBean
testImmutability, toTypedProperties, toTypedProperties, uc
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

JdbcStringBasedCacheStoreConfig

public JdbcStringBasedCacheStoreConfig(ConnectionFactoryConfig connectionFactoryConfig,
                                       TableManipulation tableManipulation)

JdbcStringBasedCacheStoreConfig

public JdbcStringBasedCacheStoreConfig()

JdbcStringBasedCacheStoreConfig

public JdbcStringBasedCacheStoreConfig(boolean manageConnectionFactory)
Method Detail

getKey2StringMapper

public Key2StringMapper getKey2StringMapper()

setKey2StringMapperClass

public void setKey2StringMapperClass(String className)
Name of the class implementing Key2StringMapper. The default value is DefaultKey2StringMapper

See Also:
Key2StringMapper

setStringsTableName

public void setStringsTableName(String stringsTableName)
Sets the name of the table where data will be stored.


setIdColumnName

public void setIdColumnName(String idColumnName)
Sets the name of the column where the id will be stored. The id is obtained through:
   key2StringMapper.getStringMapping(storedEntry.getKey());
 
Mandatory.


setDataColumnName

public void setDataColumnName(String dataColumnName)
Sets the name of the column where the StoredEntry will be binary stored. Mandatory.


setTimestampColumnName

public void setTimestampColumnName(String timestampColumnName)
Sets the name of the column where the timestamp (Long in java) will be stored. Mandatory.


setConnectionFactoryClass

public void setConnectionFactoryClass(String connectionFactoryClass)

getConnectionFactoryConfig

public ConnectionFactoryConfig getConnectionFactoryConfig()

getTableManipulation

public TableManipulation getTableManipulation()

setConnectionUrl

public void setConnectionUrl(String connectionUrl)
Jdbc connection string for connecting to the database. Mandatory.


setUserName

public void setUserName(String userName)
Database username.


setPassword

public void setPassword(String password)
Database username's password.


setDriverClass

public void setDriverClass(String driverClassName)
The name of the driver used for connecting to the database. Mandatory, will be loaded before initiating the first connection.


setIdColumnType

public void setIdColumnType(String idColumnType)
sql equivalent for java's String. Mandatory.


setDataColumnType

public void setDataColumnType(String dataColumnType)
Sets the type of the column where data will be binary stored. BLOB-like type, DBMS dependent. Mandatory.


setDropTableOnExit

public void setDropTableOnExit(boolean dropTableOnExit)

setCreateTableOnStart

public void setCreateTableOnStart(boolean createTableOnStart)

setTableManipulation

public void setTableManipulation(TableManipulation tableManipulation)

setFetchSize

public void setFetchSize(int fetchSize)
See Also:
TableManipulation.getFetchSize()

setBatchSize

public void setBatchSize(int batchSize)
See Also:
TableManipulation.getBatchSize()

getFetchSize

public int getFetchSize()
See Also:
TableManipulation.getFetchSize()

getBatchSize

public int getBatchSize()
See Also:
TableManipulation.getBatchSize()


Copyright © 2009 JBoss, a division of Red Hat. All Rights Reserved.