本文整理汇总了Java中org.infinispan.configuration.cache.PersistenceConfigurationBuilder类的典型用法代码示例。如果您正苦于以下问题:Java PersistenceConfigurationBuilder类的具体用法?Java PersistenceConfigurationBuilder怎么用?Java PersistenceConfigurationBuilder使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
PersistenceConfigurationBuilder类属于org.infinispan.configuration.cache包,在下文中一共展示了PersistenceConfigurationBuilder类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: parseCloudStore
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
private void parseCloudStore(final XMLExtendedStreamReader reader, PersistenceConfigurationBuilder loadersBuilder,
ClassLoader classLoader) throws XMLStreamException {
CloudStoreConfigurationBuilder builder = new CloudStoreConfigurationBuilder(loadersBuilder);
parseCloudStoreAttributes(reader, builder, classLoader);
while (reader.hasNext() && (reader.nextTag() != XMLStreamConstants.END_ELEMENT)) {
Element element = Element.forName(reader.getLocalName());
switch (element) {
default: {
Parser.parseStoreElement(reader, builder);
break;
}
}
}
loadersBuilder.addStore(builder);
}
示例2: parseMongoDBStore
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
private void parseMongoDBStore(XMLExtendedStreamReader reader, PersistenceConfigurationBuilder persistenceConfigurationBuilder)
throws XMLStreamException {
MongoDBStoreConfigurationBuilder builder = new MongoDBStoreConfigurationBuilder(persistenceConfigurationBuilder);
while (reader.hasNext() && (reader.nextTag() != XMLStreamConstants.END_ELEMENT)) {
Element element = Element.forName(reader.getLocalName());
switch (element) {
case CONNECTION: {
this.parseConnection(reader, builder);
break;
}
default: {
Parser80.parseStoreElement(reader, builder);
}
}
}
persistenceConfigurationBuilder.addStore(builder);
}
开发者ID:infinispan,项目名称:infinispan-cachestore-mongodb,代码行数:19,代码来源:MongoDBCacheStoreConfigurationParser.java
示例3: parseCassandraStore
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
private void parseCassandraStore(final XMLExtendedStreamReader reader,
PersistenceConfigurationBuilder persistenceBuilder) throws XMLStreamException {
CassandraStoreConfigurationBuilder builder = new CassandraStoreConfigurationBuilder(persistenceBuilder);
parseCassAttributes(reader, builder);
while (reader.hasNext() && (reader.nextTag() != XMLStreamConstants.END_ELEMENT)) {
Element element = Element.forName(reader.getLocalName());
switch (element) {
case CONNECTION_POOL: {
parseConnectionPool(reader, builder.connectionPool());
break;
}
case CASSANDRA_SERVER: {
parseServer(reader, builder.addServer());
break;
}
default: {
Parser.parseStoreElement(reader, builder);
break;
}
}
}
persistenceBuilder.addStore(builder);
}
开发者ID:infinispan,项目名称:infinispan-cachestore-cassandra,代码行数:25,代码来源:CassandraStoreConfigurationParser82.java
示例4: createCacheStoreConfig
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
@Override
protected PersistenceConfigurationBuilder createCacheStoreConfig(PersistenceConfigurationBuilder persistence,
boolean preload) {
CloudStoreConfigurationBuilder cfg = persistence.addStore(CloudStoreConfigurationBuilder.class);
cfg.preload(preload)
.provider(cs)
.endpoint(csEndpoint)
.location(csLocation)
.identity(accessKey)
.credential(secretKey)
.container(csBucket)
.compress(true);
return persistence;
}
示例5: buildCacheStoreConfig
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
@Override
protected LevelDBStoreConfigurationBuilder buildCacheStoreConfig(PersistenceConfigurationBuilder p, String discriminator) throws Exception {
LevelDBStoreConfigurationBuilder store = p.addStore(LevelDBStoreConfigurationBuilder.class);
store.location(tmpDir.getAbsolutePath() + File.separator + "leveldb" + File.separator + "data-" + discriminator);
store.expiredLocation(tmpDir.getAbsolutePath() + File.separator + "leveldb" + File.separator + "expired-data-" + discriminator);
store.implementationType(LevelDBStoreConfiguration.ImplementationType.JAVA);
return store;
}
开发者ID:danberindei,项目名称:infinispan-cachestore-leveldb,代码行数:9,代码来源:LevelDBMultiCacheStoreFunctionalTest.java
示例6: createCacheStoreConfig
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
@Override
protected PersistenceConfigurationBuilder createCacheStoreConfig(PersistenceConfigurationBuilder p, boolean preload) {
super.createStoreBuilder(p)
.preload(preload)
.implementationType(LevelDBStoreConfiguration.ImplementationType.JNI);
return p;
}
示例7: createCacheStoreConfig
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
protected LevelDBStoreConfiguration createCacheStoreConfig(PersistenceConfigurationBuilder lcb) {
cacheManager = TestCacheManagerFactory.createCacheManager(CacheMode.LOCAL, false);
LevelDBStoreConfigurationBuilder cfg = new LevelDBStoreConfigurationBuilder(lcb);
cfg.location(tmpDirectory + "/data");
cfg.expiredLocation(tmpDirectory + "/expiry");
cfg.clearThreshold(2);
return cfg.create();
}
示例8: createCacheStoreConfig
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
@Override
protected PersistenceConfigurationBuilder createCacheStoreConfig(PersistenceConfigurationBuilder persistence, boolean preload) {
CassandraStoreConfigurationBuilder cfg = persistence.addStore(CassandraStoreConfigurationBuilder.class).preload(preload);
cfg.autoCreateKeyspace(true);
cfg.addServer().host("localhost");
return persistence;
}
示例9: CloudStoreConfigurationBuilder
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
public CloudStoreConfigurationBuilder(PersistenceConfigurationBuilder builder) {
super(builder);
}
示例10: MongoDBStoreConfigurationBuilder
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
public MongoDBStoreConfigurationBuilder(PersistenceConfigurationBuilder builder) {
super(builder, MongoDBStoreConfiguration.attributeDefinitionSet());
}
开发者ID:infinispan,项目名称:infinispan-cachestore-mongodb,代码行数:4,代码来源:MongoDBStoreConfigurationBuilder.java
示例11: LevelDBStoreConfigurationBuilder
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
public LevelDBStoreConfigurationBuilder(PersistenceConfigurationBuilder builder) {
super(builder);
}
开发者ID:danberindei,项目名称:infinispan-cachestore-leveldb,代码行数:4,代码来源:LevelDBStoreConfigurationBuilder.java
示例12: createCacheStoreConfig
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
@Override
protected PersistenceConfigurationBuilder createCacheStoreConfig(PersistenceConfigurationBuilder loaders, boolean preload) {
super.createStoreBuilder(loaders).implementationType(LevelDBStoreConfiguration.ImplementationType.JAVA).preload(preload);
return loaders;
}
开发者ID:danberindei,项目名称:infinispan-cachestore-leveldb,代码行数:6,代码来源:JavaLevelDBStoreFunctionalTest.java
示例13: createCacheStoreConfig
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
protected LevelDBStoreConfiguration createCacheStoreConfig(PersistenceConfigurationBuilder lcb) {
LevelDBStoreConfigurationBuilder builder = new LevelDBStoreConfigurationBuilder(lcb);
builder.read(super.createCacheStoreConfig(lcb));
builder.implementationType(LevelDBStoreConfiguration.ImplementationType.JAVA);
return builder.create();
}
示例14: createStoreBuilder
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
LevelDBStoreConfigurationBuilder createStoreBuilder(PersistenceConfigurationBuilder loaders) {
return loaders.addStore(LevelDBStoreConfigurationBuilder.class).location(tmpDirectory + "/data").expiredLocation(tmpDirectory + "/expiry").clearThreshold(2);
}
示例15: createCacheStoreConfig
import org.infinispan.configuration.cache.PersistenceConfigurationBuilder; //导入依赖的package包/类
protected LevelDBStoreConfiguration createCacheStoreConfig(PersistenceConfigurationBuilder lcb) {
LevelDBStoreConfigurationBuilder builder = new LevelDBStoreConfigurationBuilder(lcb);
builder.read(super.createCacheStoreConfig(lcb));
builder.implementationType(LevelDBStoreConfiguration.ImplementationType.JNI);
return builder.create();
}