当前位置: 首页>>代码示例>>Java>>正文


Java SchemaAction类代码示例

本文整理汇总了Java中org.springframework.data.cassandra.config.SchemaAction的典型用法代码示例。如果您正苦于以下问题:Java SchemaAction类的具体用法?Java SchemaAction怎么用?Java SchemaAction使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


SchemaAction类属于org.springframework.data.cassandra.config包,在下文中一共展示了SchemaAction类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: hasRecreateSchemaActionSet

import org.springframework.data.cassandra.config.SchemaAction; //导入依赖的package包/类
@Test
public void hasRecreateSchemaActionSet() {
	createTestKeyspaceIfNotExists();
	this.context = new AnnotationConfigApplicationContext();
	String cityPackage = City.class.getPackage().getName();
	AutoConfigurationPackages.register(this.context, cityPackage);
	EnvironmentTestUtils.addEnvironment(this.context,
			"spring.data.cassandra.schemaAction:RECREATE_DROP_UNUSED",
			"spring.data.cassandra.keyspaceName:boot_test");
	this.context.register(CassandraAutoConfiguration.class,
			CassandraDataAutoConfiguration.class);
	this.context.refresh();
	CassandraSessionFactoryBean bean = this.context
			.getBean(CassandraSessionFactoryBean.class);
	assertThat(bean.getSchemaAction()).isEqualTo(SchemaAction.RECREATE_DROP_UNUSED);
}
 
开发者ID:vikrammane23,项目名称:https-github.com-g0t4-jenkins2-course-spring-boot,代码行数:17,代码来源:CassandraDataAutoConfigurationIntegrationTests.java

示例2: hasDefaultSchemaActionSet

import org.springframework.data.cassandra.config.SchemaAction; //导入依赖的package包/类
@Test
public void hasDefaultSchemaActionSet() {
	this.context = new AnnotationConfigApplicationContext();
	String cityPackage = City.class.getPackage().getName();
	AutoConfigurationPackages.register(this.context, cityPackage);
	this.context.register(CassandraAutoConfiguration.class,
			CassandraDataAutoConfiguration.class);
	this.context.refresh();

	CassandraSessionFactoryBean bean = this.context
			.getBean(CassandraSessionFactoryBean.class);
	assertThat(bean.getSchemaAction()).isEqualTo(SchemaAction.NONE);
}
 
开发者ID:vikrammane23,项目名称:https-github.com-g0t4-jenkins2-course-spring-boot,代码行数:14,代码来源:CassandraDataAutoConfigurationIntegrationTests.java

示例3: getSchemaAction

import org.springframework.data.cassandra.config.SchemaAction; //导入依赖的package包/类
@Override
public SchemaAction getSchemaAction() {
    return SchemaAction.RECREATE;
}
 
开发者ID:hantsy,项目名称:spring-reactive-sample,代码行数:5,代码来源:CassandraConfig.java

示例4: getSchemaAction

import org.springframework.data.cassandra.config.SchemaAction; //导入依赖的package包/类
@Override
public SchemaAction getSchemaAction() {
	return SchemaAction.RECREATE;
}
 
开发者ID:Just-Fun,项目名称:spring-data-examples,代码行数:5,代码来源:ProjectionConfiguration.java

示例5: getSchemaAction

import org.springframework.data.cassandra.config.SchemaAction; //导入依赖的package包/类
@Override
public SchemaAction getSchemaAction() {
  return SchemaAction.CREATE_IF_NOT_EXISTS;
}
 
开发者ID:Mert-Z,项目名称:spring-oauth2-cassandra-token-store,代码行数:5,代码来源:CassandraConfig.java

示例6: getSchemaAction

import org.springframework.data.cassandra.config.SchemaAction; //导入依赖的package包/类
@Override
public SchemaAction getSchemaAction() {
	return this.cassandraProperties.getSchemaAction();
}
 
开发者ID:spring-cloud-stream-app-starters,项目名称:cassandra,代码行数:5,代码来源:CassandraConfiguration.java

示例7: getSchemaAction

import org.springframework.data.cassandra.config.SchemaAction; //导入依赖的package包/类
@NotNull
public SchemaAction getSchemaAction() {
	return schemaAction;
}
 
开发者ID:spring-cloud-stream-app-starters,项目名称:cassandra,代码行数:5,代码来源:CassandraProperties.java

示例8: setSchemaAction

import org.springframework.data.cassandra.config.SchemaAction; //导入依赖的package包/类
public void setSchemaAction(SchemaAction schemaAction) {
	this.schemaAction = schemaAction;
}
 
开发者ID:spring-cloud-stream-app-starters,项目名称:cassandra,代码行数:4,代码来源:CassandraProperties.java

示例9: getSchemaAction

import org.springframework.data.cassandra.config.SchemaAction; //导入依赖的package包/类
@Override
public SchemaAction getSchemaAction() {
    return SchemaAction.RECREATE_DROP_UNUSED; // Please note that, in production, you would want a different schema
}
 
开发者ID:pivotal-cf,项目名称:cf-cassandra-spring-example-app,代码行数:5,代码来源:ApplicationConfiguration.java


注:本文中的org.springframework.data.cassandra.config.SchemaAction类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。