Skip to content

Commit

Permalink
Bump to OrientDB 1.2.
Browse files Browse the repository at this point in the history
Fixes problem with vertex duplicates #312.
  • Loading branch information
spmallette committed Oct 11, 2012
1 parent fcda13a commit 0ab461f
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 5 deletions.
4 changes: 2 additions & 2 deletions blueprints-orient-graph/pom.xml
Expand Up @@ -27,12 +27,12 @@
<dependency>
<groupId>com.orientechnologies</groupId>
<artifactId>orientdb-core</artifactId>
<version>1.1.0</version>
<version>1.2.0</version>
</dependency>
<dependency>
<groupId>com.orientechnologies</groupId>
<artifactId>orient-commons</artifactId>
<version>1.1.0</version>
<version>1.2.0</version>
</dependency>
<dependency>
<groupId>com.tinkerpop.blueprints</groupId>
Expand Down
Expand Up @@ -55,17 +55,14 @@ public class OrientBatchGraph extends OrientBaseGraph {
*/
public OrientBatchGraph(final OGraphDatabase iDatabase) {
super(iDatabase);
getRawGraph().declareIntent( new OIntentMassiveInsert() );
}

public OrientBatchGraph(final String url) {
super(url, ADMIN, ADMIN);
getRawGraph().declareIntent( new OIntentMassiveInsert() );
}

public OrientBatchGraph(final String url, final String username, final String password) {
super(url, username, password);
getRawGraph().declareIntent( new OIntentMassiveInsert() );
}

public Features getFeatures() {
Expand Down
Expand Up @@ -367,6 +367,23 @@ public void testAutomaticSuccessfulTransactionOnShutdown() {
graph.shutdown();
}

public void testVertexCountOnPreTransactionCommit() {
TransactionalGraph graph = (TransactionalGraph) graphTest.generateGraph();
Vertex v1 = graph.addVertex(null);
graph.stopTransaction(Conclusion.SUCCESS);

vertexCount(graph, 1);

Vertex v2 = graph.addVertex(null);
graph.addEdge(null, v1, v2, convertId(graph, "friend"));

vertexCount(graph, 2);

graph.stopTransaction(Conclusion.SUCCESS);

vertexCount(graph, 2);

}

public void testBulkTransactionsOnEdges() {
TransactionalGraph graph = (TransactionalGraph) graphTest.generateGraph();
Expand Down

0 comments on commit 0ab461f

Please sign in to comment.