當前位置: 首頁>>代碼示例>>Java>>正文


Java SimpleBulkPlacementStrategy類代碼示例

本文整理匯總了Java中com.thinkaurelius.titan.graphdb.database.idassigner.placement.SimpleBulkPlacementStrategy的典型用法代碼示例。如果您正苦於以下問題:Java SimpleBulkPlacementStrategy類的具體用法?Java SimpleBulkPlacementStrategy怎麽用?Java SimpleBulkPlacementStrategy使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


SimpleBulkPlacementStrategy類屬於com.thinkaurelius.titan.graphdb.database.idassigner.placement包,在下文中一共展示了SimpleBulkPlacementStrategy類的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: getConfiguration

import com.thinkaurelius.titan.graphdb.database.idassigner.placement.SimpleBulkPlacementStrategy; //導入依賴的package包/類
@Override
public WriteConfiguration getConfiguration() {
    WriteConfiguration config = getBaseConfiguration();
    ModifiableConfiguration mconf = new ModifiableConfiguration(GraphDatabaseConfiguration.ROOT_NS,config, BasicConfiguration.Restriction.NONE);
    // Let GraphDatabaseConfiguration's config freezer set CLUSTER_PARTITION
    //mconf.set(GraphDatabaseConfiguration.CLUSTER_PARTITION,true);
    mconf.set(GraphDatabaseConfiguration.CLUSTER_MAX_PARTITIONS,numPartitions);
    //uses SimpleBulkPlacementStrategy by default
    mconf.set(SimpleBulkPlacementStrategy.CONCURRENT_PARTITIONS,3*numPartitions);
    return config;
}
 
開發者ID:graben1437,項目名稱:titan1withtp3.1,代碼行數:12,代碼來源:TitanPartitionGraphTest.java

示例2: getHBaseConfiguration

import com.thinkaurelius.titan.graphdb.database.idassigner.placement.SimpleBulkPlacementStrategy; //導入依賴的package包/類
public static ModifiableConfiguration getHBaseConfiguration(String tableName) {
        ModifiableConfiguration config = GraphDatabaseConfiguration.buildGraphConfiguration();
        config.set(GraphDatabaseConfiguration.STORAGE_BACKEND, "hbase");
        if (!StringUtils.isEmpty(tableName)) config.set(HBaseStoreManager.HBASE_TABLE,tableName);
        config.set(GraphDatabaseConfiguration.TIMESTAMP_PROVIDER, HBaseStoreManager.PREFERRED_TIMESTAMPS);
        config.set(SimpleBulkPlacementStrategy.CONCURRENT_PARTITIONS, 1);
//        config.set(GraphDatabaseConfiguration.STORAGE_NS.getName()+"."+HBaseStoreManager.HBASE_CONFIGURATION_NAMESPACE+
//                    ".hbase.zookeeper.quorum","localhost");
//        config.set(GraphDatabaseConfiguration.STORAGE_NS.getName()+"."+HBaseStoreManager.HBASE_CONFIGURATION_NAMESPACE+
//                "hbase.zookeeper.property.clientPort",2181);
        return config;
    }
 
開發者ID:graben1437,項目名稱:titan1withtp3.1,代碼行數:13,代碼來源:HBaseStorageSetup.java

示例3: getConfiguration

import com.thinkaurelius.titan.graphdb.database.idassigner.placement.SimpleBulkPlacementStrategy; //導入依賴的package包/類
@Override
public WriteConfiguration getConfiguration() {
    WriteConfiguration config = getBaseConfiguration();
    ModifiableConfiguration mconf = new ModifiableConfiguration(GraphDatabaseConfiguration.ROOT_NS,config, BasicConfiguration.Restriction.NONE);
    // Let GraphDatabaseConfiguration's config freezer set CLUSTER_PARTITION
    //mconf.set(GraphDatabaseConfiguration.CLUSTER_PARTITION,true);
    mconf.set(GraphDatabaseConfiguration.CLUSTER_MAX_PARTITIONS,numPartitions);
    //uses SimpleBulkPlacementStrategy by default
    mconf.set(SimpleBulkPlacementStrategy.CONCURRENT_PARTITIONS,16);
    return config;
}
 
開發者ID:graben1437,項目名稱:titan0.5.4-hbase1.1.1-custom,代碼行數:12,代碼來源:TitanPartitionGraphTest.java

示例4: getHBaseConfiguration

import com.thinkaurelius.titan.graphdb.database.idassigner.placement.SimpleBulkPlacementStrategy; //導入依賴的package包/類
public static ModifiableConfiguration getHBaseConfiguration() {
        ModifiableConfiguration config = GraphDatabaseConfiguration.buildConfiguration();
        config.set(GraphDatabaseConfiguration.STORAGE_BACKEND, "hbase");
        config.set(GraphDatabaseConfiguration.CLUSTER_PARTITION, true);
        config.set(GraphDatabaseConfiguration.TIMESTAMP_PROVIDER, HBaseStoreManager.PREFERRED_TIMESTAMPS);
        config.set(SimpleBulkPlacementStrategy.CONCURRENT_PARTITIONS, 1);
//        config.set(GraphDatabaseConfiguration.STORAGE_NS.getName()+"."+HBaseStoreManager.HBASE_CONFIGURATION_NAMESPACE+
//                    ".hbase.zookeeper.quorum","localhost");
//        config.set(GraphDatabaseConfiguration.STORAGE_NS.getName()+"."+HBaseStoreManager.HBASE_CONFIGURATION_NAMESPACE+
//                "hbase.zookeeper.property.clientPort",2181);
        return config;
    }
 
開發者ID:graben1437,項目名稱:titan0.5.4-hbase1.1.1-custom,代碼行數:13,代碼來源:HBaseStorageSetup.java


注:本文中的com.thinkaurelius.titan.graphdb.database.idassigner.placement.SimpleBulkPlacementStrategy類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。