use of com.thinkaurelius.titan.diskstorage.configuration.ModifiableConfiguration in project titan by thinkaurelius.
the class InMemoryGraphComputerProvider method getTitanConfiguration.
@Override
public ModifiableConfiguration getTitanConfiguration(String graphName, Class<?> test, String testMethodName) {
ModifiableConfiguration config = StorageSetup.getInMemoryConfiguration();
config.set(GraphDatabaseConfiguration.STORAGE_TRANSACTIONAL, false);
return config;
}
use of com.thinkaurelius.titan.diskstorage.configuration.ModifiableConfiguration in project titan by thinkaurelius.
the class TitanOperationCountingTest method getConfiguration.
@Override
public WriteConfiguration getConfiguration() {
WriteConfiguration config = getBaseConfiguration();
ModifiableConfiguration mconf = new ModifiableConfiguration(GraphDatabaseConfiguration.ROOT_NS, config, BasicConfiguration.Restriction.NONE);
mconf.set(BASIC_METRICS, true);
mconf.set(METRICS_MERGE_STORES, false);
mconf.set(PROPERTY_PREFETCHING, false);
mconf.set(DB_CACHE, false);
return config;
}
use of com.thinkaurelius.titan.diskstorage.configuration.ModifiableConfiguration in project titan by thinkaurelius.
the class TitanPartitionGraphTest method getConfiguration.
@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;
}
use of com.thinkaurelius.titan.diskstorage.configuration.ModifiableConfiguration in project titan by thinkaurelius.
the class InMemoryGraphTest method clopen.
@Override
public void clopen(Object... settings) {
if (settings != null && settings.length > 0) {
if (graph != null && graph.isOpen()) {
Preconditions.checkArgument(!graph.vertices().hasNext() && !graph.edges().hasNext(), "Graph cannot be re-initialized for InMemory since that would delete all data");
graph.close();
}
Map<TestConfigOption, Object> options = validateConfigOptions(settings);
ModifiableConfiguration config = GraphDatabaseConfiguration.buildGraphConfiguration();
config.set(GraphDatabaseConfiguration.STORAGE_BACKEND, "inmemory");
for (Map.Entry<TestConfigOption, Object> option : options.entrySet()) {
config.set(option.getKey().option, option.getValue(), option.getKey().umbrella);
}
open(config.getConfiguration());
}
newTx();
}
use of com.thinkaurelius.titan.diskstorage.configuration.ModifiableConfiguration in project titan by thinkaurelius.
the class InMemoryPartitionGraphTest method getBaseConfiguration.
@Override
public WriteConfiguration getBaseConfiguration() {
ModifiableConfiguration config = GraphDatabaseConfiguration.buildGraphConfiguration();
config.set(GraphDatabaseConfiguration.STORAGE_BACKEND, "inmemory");
config.set(GraphDatabaseConfiguration.IDS_FLUSH, false);
return config.getConfiguration();
}
Aggregations