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


Java DataStoreFactory.createProps方法代码示例

本文整理汇总了Java中org.apache.gora.store.DataStoreFactory.createProps方法的典型用法代码示例。如果您正苦于以下问题:Java DataStoreFactory.createProps方法的具体用法?Java DataStoreFactory.createProps怎么用?Java DataStoreFactory.createProps使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.gora.store.DataStoreFactory的用法示例。


在下文中一共展示了DataStoreFactory.createProps方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: setUp

import org.apache.gora.store.DataStoreFactory; //导入方法依赖的package包/类
@Before
@SuppressWarnings("unchecked")
public void setUp() throws Exception {
  cluster = new MiniAccumuloCluster(temporaryFolder.getRoot(), PASSWORD);
  cluster.start();

  Properties properties = DataStoreFactory.createProps();
  properties.setProperty(
      GORA_DATASTORE + AccumuloStore.MOCK_PROPERTY,
      "false");
  properties.setProperty(
      GORA_DATASTORE + AccumuloStore.INSTANCE_NAME_PROPERTY,
      cluster.getInstanceName());
  properties.setProperty(
      GORA_DATASTORE + AccumuloStore.ZOOKEEPERS_NAME_PROPERTY,
      cluster.getZooKeepers());
  properties.setProperty(
      GORA_DATASTORE + AccumuloStore.PASSWORD_PROPERTY,
      PASSWORD);

  employeeStore = DataStoreFactory.createDataStore(
      AccumuloStore.class,
      String.class,
      Employee.class,
      new Configuration(),
      properties);
}
 
开发者ID:jianglibo,项目名称:gora-boot,代码行数:28,代码来源:AuthenticationTokenTest.java

示例2: init

import org.apache.gora.store.DataStoreFactory; //导入方法依赖的package包/类
/**
 *
 * Initialize class and create DataStore instance
 *
 * @param config component configuration
 * @throws IOException
 */
private void init(final GoraConfiguration config) throws IOException {
    this.goraProperties = DataStoreFactory.createProps();
    this.dataStore = DataStoreFactory.getDataStore(goraProperties.getProperty(GORA_DEFAULT_DATASTORE_KEY,
                                                                              config.getDataStoreClass()),
                                                    config.getKeyClass(),
                                                    config.getValueClass(),
                                                    this.configuration);
}
 
开发者ID:HydAu,项目名称:Camel,代码行数:16,代码来源:GoraComponent.java

示例3: createDataStore

import org.apache.gora.store.DataStoreFactory; //导入方法依赖的package包/类
/**
 * Creates a generic data store using the data store class.
 * set using the class property
 * @param <K> key class
 * @param <T> value class
 * @param keyClass key class used
 * @param persistentClass persistent class used
 * @return created data store
 * @throws GoraException exception threw
 */
@SuppressWarnings("unchecked")
public static <K, T extends Persistent> DataStore<K, T>
createDataStore(Class<K> keyClass, Class<T> persistentClass)
  throws GoraException {
  DataStoreFactory.createProps();
  DataStore<K, T> dataStore =
      DataStoreFactory.createDataStore((Class<? extends DataStore<K, T>>)
                                        DATASTORECLASS,
                                        keyClass, persistentClass,
                                        getConf());

  return dataStore;
}
 
开发者ID:renato2099,项目名称:giraph-gora,代码行数:24,代码来源:GoraUtils.java

示例4: main

import org.apache.gora.store.DataStoreFactory; //导入方法依赖的package包/类
/**
 * @param args
 * @throws IOException 
 * @throws IllegalAccessException 
 * @throws InstantiationException 
 */
public static void main(String[] args) throws InstantiationException, IllegalAccessException, IOException {
  Properties props = DataStoreFactory.createProps();
  ChefSoftwareProvisioning.performChefComputeServiceBootstrapping(props);
}
 
开发者ID:apache,项目名称:gora,代码行数:11,代码来源:ChefSoftwareProvisioning.java

示例5: main

import org.apache.gora.store.DataStoreFactory; //导入方法依赖的package包/类
/**
 * Right now the Rackspace Orchestration and Services Provisioning
 * requires no arguments. It can be invoked from
 * <code>$GORA_HOME/bin/gora goracisetup</code>
 * @param args
 * @throws IllegalAccessException 
 * @throws InstantiationException 
 * @throws NoSuchElementException 
 */
public static void main(String[] args) throws NoSuchElementException, InstantiationException, IllegalAccessException, IOException {
  Properties properties = DataStoreFactory.createProps();
  performRackspaceOrchestration(properties);
}
 
开发者ID:apache,项目名称:gora,代码行数:14,代码来源:RackspaceOrchestration.java


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