]
Tristan Tarrant commented on ISPN-5552:
---------------------------------------
You'd better ask on the forum
Cannot start persistence cache: CacheException
----------------------------------------------
Key: ISPN-5552
URL:
https://issues.jboss.org/browse/ISPN-5552
Project: Infinispan
Issue Type: Bug
Affects Versions: 6.0.3.Final
Environment: WildFly 8.2.0 / Linux
Reporter: Veli Cris
Hi,
I have the following configuration for persistence cache (MySQL) and when I try to start
the cache I get CacheException error. Basically what I want is to save the records from
cache called 'mycache' in MySQL table called 'bean.bean_session'. Thank
you.
org.infinispan.commons.CacheException: Unable to invoke method public void
org.infinispan.persistence.manager.PersistenceManagerImpl.start() on object of type
PersistenceManagerImpl
ConfigurationBuilder builder = new ConfigurationBuilder();
Configuration config = builder.persistence()
.addStore(JdbcBinaryStoreConfigurationBuilder.class)
.fetchPersistentState(false)
.ignoreModifications(false)
.purgeOnStartup(false)
.table()
.dropOnExit(true)
.createOnStart(true)
.tableNamePrefix("bean_session")
.idColumnName("id").idColumnType("INT(11)")
.dataColumnName("string").dataColumnType("TEXT")
.timestampColumnName("timestamp").timestampColumnType("TIMESTAMP")
.connectionPool()
.connectionUrl("jdbc:mysql://localhost:3306/bean")
.username("root").password("1234567")
.driverClass("com.mysql.jdbc.Driver").build();
DefaultCacheManager manager = new DefaultCacheManager();
manager.defineConfiguration("mycache", config);
Cache cache = manager.getCache("mycache");
cache.put("1", "1");
cache.put("2", "2");
cache.put("3", "3");
cache.start();