我正在将项目从 8.2.4.Final 迁移到 Infinispan 9.1.0.Final 并得到下一个异常:
org.infinispan.commons.CacheConfigurationException:ISPN000441:事务缓存不支持异步缓存模式“REPL_ASYNC”
相关代码:
new ConfigurationBuilder()
.jmxStatistics()
.enabled(false)
.available(false)
.clustering()
.cacheMode(CacheMode.REPL_ASYNC)
.stateTransfer().awaitInitialTransfer(false)
.transaction()
.transactionManagerLookup(new DummyTransactionManagerLookup())
.transactionMode(TransactionMode.TRANSACTIONAL)
.lockingMode(LockingMode.PESSIMISTIC)
.recovery()
.enabled(false)
.invocationBatching()
.enable(false)
.indexing()
.index(Index.ALL)
.addProperty("default.indexmanager", "near-real-time")
.addProperty("default.directory_provider", "ram")
.addProperty("default.worker.execution", "sync")
.addProperty("default.exclusive_index_use", "true")
.addProperty("default.reader.strategy", "shared")
.build();
和问题组合在这里,但在 8.2.4.Final 版本中效果很好。
.cacheMode(CacheMode.REPL_ASYNC)
.transactionMode(TransactionMode.TRANSACTIONAL) // Maybe is there another way to lock put operations?
我应该如何重新配置缓存以保存其特征?