Skip to content

Commit

Permalink
Added pseudo test to facilitate manual observation of chunking of bul…
Browse files Browse the repository at this point in the history
…k writes
  • Loading branch information
criminosis committed Jun 12, 2024
1 parent 0989180 commit af88b6a
Showing 1 changed file with 17 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,12 @@
import org.janusgraph.graphdb.JanusGraphIndexTest;
import org.janusgraph.graphdb.configuration.GraphDatabaseConfiguration;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.testcontainers.junit.jupiter.Container;

import java.time.Duration;
import java.util.stream.IntStream;

import static org.janusgraph.graphdb.configuration.GraphDatabaseConfiguration.FORCE_INDEX_USAGE;
import static org.janusgraph.graphdb.configuration.GraphDatabaseConfiguration.INDEX_NAME;
Expand Down Expand Up @@ -105,6 +107,21 @@ public void indexShouldNotExistAfterDeletion() throws Exception {
assertFalse(esr.indexExists(expectedIndexName));
}

@Test
//Disabled to not slow down CI/CD builds given there's nothing to assert
//intended for manual observation of the bulk chunking to ElasticSearch
@Disabled
public void manuallyObserveBulkWritingChunking() {
clopen(option(ElasticSearchIndex.BULK_CHUNK_SIZE_LIMIT_BYTES, INDEX), 100);
PropertyKey key = mgmt.makePropertyKey("some-field").dataType(String.class).make();
mgmt.buildIndex("testChunkingIndex", Vertex.class).addKey(key).buildMixedIndex(INDEX);
mgmt.commit();

//Write 10 vertices that will each individually be split up into their own chunks due to the limit configured
IntStream.range(0, 10).forEach(i -> graph.traversal().addV().property(key.name(), "foobar").toList());
graph.tx().commit();
}

@Override
public boolean supportsLuceneStyleQueries() {
return true;
Expand Down

1 comment on commit af88b6a

@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: af88b6a Previous: 0989180 Ratio
org.janusgraph.JanusGraphSpeedBenchmark.basicAddAndDelete 12943.623437618398 ms/op 12428.865867241031 ms/op 1.04
org.janusgraph.GraphCentricQueryBenchmark.getVertices 916.0810520045242 ms/op 911.5473450718421 ms/op 1.00
org.janusgraph.MgmtOlapJobBenchmark.runClearIndex 216.40252556159422 ms/op 216.4931939264493 ms/op 1.00
org.janusgraph.MgmtOlapJobBenchmark.runReindex 337.99498552321427 ms/op 340.74630982321423 ms/op 0.99
org.janusgraph.JanusGraphSpeedBenchmark.basicCount 236.474856552522 ms/op 226.26927395125318 ms/op 1.05
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesAllPropertiesWithAllMultiQuerySlicesUnderMaxRequestsPerConnection 4882.664304947668 ms/op 4801.71602980782 ms/op 1.02
org.janusgraph.CQLMultiQueryBenchmark.getElementsWithUsingEmitRepeatSteps 17196.631527177862 ms/op 16069.753835788153 ms/op 1.07
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesMultiplePropertiesWithSmallBatch 20368.17869689111 ms/op 18905.180757340404 ms/op 1.08
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.vertexCentricPropertiesFetching 57517.42113470001 ms/op 53985.8428783 ms/op 1.07
org.janusgraph.CQLMultiQueryDropBenchmark.dropVertices 1576.3972770539701 ms/op 1516.7583697220782 ms/op 1.04
org.janusgraph.CQLMultiQueryBenchmark.getAllElementsTraversedFromOuterVertex 8105.636461159875 ms/op 8043.976007737834 ms/op 1.01
org.janusgraph.CQLMultiQueryBenchmark.getVerticesWithDoubleUnion 383.89582071624324 ms/op 373.368633566541 ms/op 1.03
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesAllPropertiesWithUnlimitedBatch 4180.608973291587 ms/op 4218.250565827849 ms/op 0.99
org.janusgraph.CQLMultiQueryBenchmark.getNames 8132.437150927413 ms/op 8110.747154668088 ms/op 1.00
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesThreePropertiesWithAllMultiQuerySlicesUnderMaxRequestsPerConnection 5835.682858119504 ms/op 5422.12104862155 ms/op 1.08
org.janusgraph.CQLMultiQueryBenchmark.getLabels 7195.18001689772 ms/op 7443.3811480132 ms/op 0.97
org.janusgraph.CQLMultiQueryBenchmark.getVerticesFilteredByAndStep 439.5605725143163 ms/op 410.3775224750847 ms/op 1.07
org.janusgraph.CQLMultiQueryBenchmark.getVerticesFromMultiNestedRepeatStepStartingFromSingleVertex 12704.757164106944 ms/op 12295.737536800294 ms/op 1.03
org.janusgraph.CQLMultiQueryBenchmark.getVerticesWithCoalesceUsage 357.68361456704 ms/op 360.29696767582436 ms/op 0.99
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesMultiplePropertiesWithAllMultiQuerySlicesUnderMaxRequestsPerConnection 13678.578432239643 ms/op 13726.353004594705 ms/op 1.00
org.janusgraph.CQLMultiQueryBenchmark.getIdToOutVerticesProjection 247.2319831133538 ms/op 245.52876706790423 ms/op 1.01
org.janusgraph.CQLMultiQueryMultiSlicesBenchmark.getValuesMultiplePropertiesWithUnlimitedBatch 14541.667763122143 ms/op 14197.794723106388 ms/op 1.02
org.janusgraph.CQLMultiQueryBenchmark.getNeighborNames 8185.312370196865 ms/op 7993.805096534933 ms/op 1.02
org.janusgraph.CQLMultiQueryBenchmark.getElementsWithUsingRepeatUntilSteps 9030.080356990153 ms/op 8794.403020416585 ms/op 1.03
org.janusgraph.CQLMultiQueryBenchmark.getAdjacentVerticesLocalCounts 8908.856644150741 ms/op 8397.6310219059 ms/op 1.06

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

Please sign in to comment.