Skip to content

Commit

Permalink
Drop benchmark graph data after CQLMultiQueryDropBenchmark
Browse files Browse the repository at this point in the history
Fixes #4434

Signed-off-by: Oleksandr Porunov <[email protected]>
  • Loading branch information
porunov committed May 7, 2024
1 parent c3bdf61 commit cd3bff8
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 16 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,6 @@ janusgraph-*/pom.xml.versionsBackup
/site/

*.hprof
.factorypath
.factorypath

janusgraph-benchmark/benchmark.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import org.janusgraph.core.JanusGraphVertex;
import org.janusgraph.core.PropertyKey;
import org.janusgraph.core.schema.JanusGraphManagement;
import org.janusgraph.diskstorage.BackendException;
import org.janusgraph.diskstorage.configuration.ModifiableConfiguration;
import org.janusgraph.diskstorage.configuration.WriteConfiguration;
import org.janusgraph.diskstorage.cql.CQLConfigOptions;
Expand Down Expand Up @@ -71,33 +72,27 @@ public WriteConfiguration getConfiguration() {
public void setUp() throws Exception {
graph = JanusGraphFactory.open(getConfiguration());

boolean alreadyAdded = true;
JanusGraphManagement mgmt = graph.openManagement();
if (!mgmt.containsPropertyKey("id")) {
mgmt.makePropertyKey("id").dataType(Integer.class).cardinality(Cardinality.SINGLE).make();
PropertyKey nameProp = mgmt.makePropertyKey("name").dataType(String.class).cardinality(Cardinality.SINGLE).make();
mgmt.makePropertyKey("details").dataType(String.class).cardinality(Cardinality.SINGLE).make();
mgmt.buildIndex("nameIndex", Vertex.class).addKey(nameProp).buildCompositeIndex();

alreadyAdded = false;
}
mgmt.makePropertyKey("id").dataType(Integer.class).cardinality(Cardinality.SINGLE).make();
PropertyKey nameProp = mgmt.makePropertyKey("name").dataType(String.class).cardinality(Cardinality.SINGLE).make();
mgmt.makePropertyKey("details").dataType(String.class).cardinality(Cardinality.SINGLE).make();
mgmt.buildIndex("nameIndex", Vertex.class).addKey(nameProp).buildCompositeIndex();

mgmt.commit();

if (!alreadyAdded) {
addVertices();
}
addVertices();
}

@TearDown
public void tearDown() {
graph.close();
public void tearDown() throws BackendException {
JanusGraphFactory.drop(graph);
}

@Benchmark
public Integer dropVertices() {

JanusGraphTransaction tx = graph.buildTransaction().start();
Integer dropCount = 0;
Integer dropCount;
if (isMultiDrop) {

List<JanusGraphVertex> vertices = tx.traversal()
Expand Down

1 comment on commit cd3bff8

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark

Benchmark suite Current: cd3bff8 Previous: c8792aa Ratio
org.janusgraph.JanusGraphSpeedBenchmark.basicAddAndDelete 12857.505793573424 ms/op 12933.219068971923 ms/op 0.99
org.janusgraph.GraphCentricQueryBenchmark.getVertices 879.6628946208857 ms/op 929.0686750649414 ms/op 0.95
org.janusgraph.MgmtOlapJobBenchmark.runClearIndex 215.8298076431159 ms/op 215.98180543333334 ms/op 1.00
org.janusgraph.MgmtOlapJobBenchmark.runReindex 335.6358708607143 ms/op 348.8265452326923 ms/op 0.96
org.janusgraph.JanusGraphSpeedBenchmark.basicCount 205.65600161025617 ms/op 227.8074437066411 ms/op 0.90
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesAllPropertiesWithAllMultiQuerySlicesUnderMaxRequestsPerConnection 4731.658172414107 ms/op 4880.398383755226 ms/op 0.97
org.janusgraph.CQLMultiQueryBenchmark.getElementsWithUsingEmitRepeatSteps 16668.67550763897 ms/op 17909.154248616192 ms/op 0.93
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesMultiplePropertiesWithSmallBatch 18859.51794174788 ms/op 18799.44054118485 ms/op 1.00
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.vertexCentricPropertiesFetching 57080.954078966664 ms/op 55455.590322899996 ms/op 1.03
org.janusgraph.CQLMultiQueryDropBenchmark.dropVertices 1517.2549644899923 ms/op
org.janusgraph.CQLMultiQueryBenchmark.getAllElementsTraversedFromOuterVertex 8021.779508729234 ms/op 8339.218499689177 ms/op 0.96
org.janusgraph.CQLMultiQueryBenchmark.getVerticesWithDoubleUnion 380.01868534643165 ms/op 371.31223395833683 ms/op 1.02
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesAllPropertiesWithUnlimitedBatch 4200.829386305637 ms/op 4227.4425002369935 ms/op 0.99
org.janusgraph.CQLMultiQueryBenchmark.getNames 7964.887624449522 ms/op 8528.923591561108 ms/op 0.93
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesThreePropertiesWithAllMultiQuerySlicesUnderMaxRequestsPerConnection 5769.410147802174 ms/op 5366.416493988495 ms/op 1.08
org.janusgraph.CQLMultiQueryBenchmark.getLabels 7035.149560807728 ms/op 7119.612218557372 ms/op 0.99
org.janusgraph.CQLMultiQueryBenchmark.getVerticesFilteredByAndStep 418.3544883155036 ms/op 416.6330074327548 ms/op 1.00
org.janusgraph.CQLMultiQueryBenchmark.getVerticesFromMultiNestedRepeatStepStartingFromSingleVertex 12177.055481261175 ms/op 13040.1543998325 ms/op 0.93
org.janusgraph.CQLMultiQueryBenchmark.getVerticesWithCoalesceUsage 349.7936931317007 ms/op 366.6865794040481 ms/op 0.95
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesMultiplePropertiesWithAllMultiQuerySlicesUnderMaxRequestsPerConnection 14301.704779571428 ms/op 14169.280107965806 ms/op 1.01
org.janusgraph.CQLMultiQueryBenchmark.getIdToOutVerticesProjection 242.22656307567377 ms/op 243.11426684096145 ms/op 1.00
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesMultiplePropertiesWithUnlimitedBatch 15271.552434849364 ms/op 14724.027508337518 ms/op 1.04
org.janusgraph.CQLMultiQueryBenchmark.getNeighborNames 8080.848615868158 ms/op 8379.61509861012 ms/op 0.96
org.janusgraph.CQLMultiQueryBenchmark.getElementsWithUsingRepeatUntilSteps 9153.776559652873 ms/op 9197.912189783667 ms/op 1.00
org.janusgraph.CQLMultiQueryBenchmark.getAdjacentVerticesLocalCounts 8406.54625448299 ms/op 8786.588147997933 ms/op 0.96

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.