Skip to content

Commit dfef181

Browse files
authored
Merge pull request #10292 from DarthMax/more_pathfinding_algos
Implement simple path finding write procs
2 parents baeacfd + 117cc36 commit dfef181

File tree

13 files changed

+31
-35
lines changed

13 files changed

+31
-35
lines changed

applications/graph-store-catalog/src/main/java/org/neo4j/gds/applications/graphstorecatalog/CatalogConfigurationService.java

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ public GraphProjectFromStoreConfig parseNativeProjectConfiguration(
7070

7171
var configuration = GraphProjectFromStoreConfig.of(
7272
user.getUsername(),
73-
graphName.getValue(),
73+
graphName.value(),
7474
nodeProjection,
7575
relationshipProjection,
7676
wrappedRawConfiguration
@@ -92,7 +92,7 @@ public GraphProjectFromCypherConfig parseCypherProjectConfiguration(
9292

9393
var configuration = GraphProjectFromCypherConfig.of(
9494
user.getUsername(),
95-
graphName.getValue(),
95+
graphName.value(),
9696
nodeQuery,
9797
relationshipQuery,
9898
wrappedRawConfiguration
@@ -162,8 +162,8 @@ GraphProjectFromGraphConfig parseSubGraphProjectConfiguration(
162162

163163
var configuration = GraphProjectFromGraphConfig.of(
164164
user.getUsername(),
165-
graphName.getValue(),
166-
originGraphName.getValue(),
165+
graphName.value(),
166+
originGraphName.value(),
167167
nodeFilter,
168168
relationshipFilter,
169169
originGraphConfiguration.config(),
@@ -183,7 +183,7 @@ GraphDropNodePropertiesConfig parseGraphDropNodePropertiesConfiguration(
183183
var cypherConfig = CypherMapWrapper.create(rawConfiguration);
184184

185185
var configuration = GraphDropNodePropertiesConfig.of(
186-
graphName.getValue(),
186+
graphName.value(),
187187
nodeProperties,
188188
cypherConfig
189189
);
@@ -201,7 +201,7 @@ void validateDropGraphPropertiesConfiguration(
201201
var cypherConfig = CypherMapWrapper.create(rawConfiguration);
202202

203203
var configuration = GraphRemoveGraphPropertiesConfig.of(
204-
graphName.getValue(),
204+
graphName.value(),
205205
graphProperty,
206206
cypherConfig
207207
);
@@ -217,7 +217,7 @@ void validateGraphStreamGraphPropertiesConfig(
217217
var cypherConfig = CypherMapWrapper.create(rawConfiguration);
218218

219219
var configuration = GraphStreamGraphPropertiesConfig.of(
220-
graphName.getValue(),
220+
graphName.value(),
221221
graphProperty,
222222
cypherConfig
223223
);
@@ -234,7 +234,7 @@ GraphStreamNodePropertiesConfig parseGraphStreamNodePropertiesConfiguration(
234234
var cypherConfig = CypherMapWrapper.create(rawConfiguration);
235235

236236
var configuration = GraphStreamNodePropertiesConfig.of(
237-
graphName.getValue(),
237+
graphName.value(),
238238
nodeProperties,
239239
nodeLabels,
240240
cypherConfig
@@ -254,7 +254,7 @@ GraphStreamRelationshipPropertiesConfig parseGraphStreamRelationshipPropertiesCo
254254
var cypherConfig = CypherMapWrapper.create(rawConfiguration);
255255

256256
var configuration = GraphStreamRelationshipPropertiesConfig.of(
257-
graphName.getValue(),
257+
graphName.value(),
258258
relationshipProperties,
259259
relationshipTypes,
260260
cypherConfig
@@ -273,7 +273,7 @@ GraphStreamRelationshipsConfig parseGraphStreamRelationshipsConfiguration(
273273
var cypherConfig = CypherMapWrapper.create(rawConfiguration);
274274

275275
var configuration = GraphStreamRelationshipsConfig.of(
276-
graphName.getValue(),
276+
graphName.value(),
277277
relationshipTypes,
278278
cypherConfig
279279
);
@@ -292,7 +292,7 @@ GraphWriteNodePropertiesConfig parseGraphWriteNodePropertiesConfiguration(
292292
var cypherConfig = CypherMapWrapper.create(rawConfiguration);
293293

294294
var configuration = GraphWriteNodePropertiesConfig.of(
295-
graphName.getValue(),
295+
graphName.value(),
296296
nodeProperties,
297297
nodeLabels,
298298
cypherConfig
@@ -345,7 +345,7 @@ RandomGraphGeneratorConfig parseRandomGraphGeneratorConfig(
345345

346346
var configuration = RandomGraphGeneratorConfig.of(
347347
user.getUsername(),
348-
graphName.getValue(),
348+
graphName.value(),
349349
nodeCount,
350350
averageDegree,
351351
cypherConfig

applications/graph-store-catalog/src/main/java/org/neo4j/gds/applications/graphstorecatalog/DefaultGraphCatalogApplications.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -563,7 +563,7 @@ public GraphDropNodePropertiesResult dropNodeProperties(
563563
);
564564

565565
return new GraphDropNodePropertiesResult(
566-
graphName.getValue(),
566+
graphName.value(),
567567
droppedProperties,
568568
numberOfPropertiesRemoved
569569
);
@@ -604,7 +604,7 @@ public GraphDropRelationshipResult dropRelationships(
604604
relationshipType
605605
);
606606

607-
return new GraphDropRelationshipResult(graphName.getValue(), relationshipType, result);
607+
return new GraphDropRelationshipResult(graphName.value(), relationshipType, result);
608608
}
609609

610610
@Override

applications/graph-store-catalog/src/main/java/org/neo4j/gds/applications/graphstorecatalog/ExportToCsvApplication.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ FileExportResult run(GraphName graphName, GraphStoreToFileExporterConfig configu
8686
);
8787

8888
return new FileExportResult(
89-
graphName.getValue(),
89+
graphName.value(),
9090
configuration.exportName(),
9191
graphStore.nodeCount(),
9292
graphStore.relationshipCount(),

applications/graph-store-catalog/src/main/java/org/neo4j/gds/applications/graphstorecatalog/ExportToDatabaseApplication.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ DatabaseExportResult run(
101101
var end = System.nanoTime();
102102

103103
return new DatabaseExportResult(
104-
graphName.getValue(),
104+
graphName.value(),
105105
configuration.databaseName(),
106106
graphStore.nodeCount(),
107107
graphStore.relationshipCount(),

applications/graph-store-catalog/src/main/java/org/neo4j/gds/applications/graphstorecatalog/GraphSamplingApplication.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,8 @@ RandomWalkSamplingResult sample(
8282

8383
var rwrProcConfig = RandomWalkWithRestartsConfiguration.of(
8484
user.getUsername(),
85-
graphName.getValue(),
86-
originGraphName.getValue(),
85+
graphName.value(),
86+
originGraphName.value(),
8787
graphProjectConfig,
8888
cypherMap
8989
);
@@ -93,8 +93,8 @@ RandomWalkSamplingResult sample(
9393
var projectMillis = progressTimer.stop().getDuration();
9494

9595
return new RandomWalkSamplingResult(
96-
graphName.getValue(),
97-
originGraphName.getValue(),
96+
graphName.value(),
97+
originGraphName.value(),
9898
sampledGraphStore.nodeCount(),
9999
sampledGraphStore.relationshipCount(),
100100
samplerAlgorithm.startNodesCount(),

applications/graph-store-catalog/src/main/java/org/neo4j/gds/applications/graphstorecatalog/ListGraphApplication.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public List<Pair<GraphStoreCatalogEntry, Map<String, Object>>> list(
5656
TerminationFlag terminationFlag
5757
) {
5858
Predicate<String> graphNameFilter = graphName
59-
.map(GraphName::getValue)
59+
.map(graphName1 -> graphName1.value())
6060
.map(name -> (Predicate<String>) name::equals)
6161
.orElseGet(() -> __ -> true);
6262
var graphEntries = graphListingService.listGraphs(user)

applications/graph-store-catalog/src/main/java/org/neo4j/gds/applications/graphstorecatalog/NodeLabelMutatorApplication.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ public MutateLabelResult compute(
3939
MutateLabelConfig configuration,
4040
Expression nodeFilter
4141
) {
42-
var resultBuilder = MutateLabelResult.builder(graphName.getValue(), nodeLabelAsString)
42+
var resultBuilder = MutateLabelResult.builder(graphName.value(), nodeLabelAsString)
4343
.withConfig(configuration.toMap());
4444

4545
try (ProgressTimer ignored = ProgressTimer.start(resultBuilder::withMutateMillis)) {

applications/graph-store-catalog/src/main/java/org/neo4j/gds/applications/graphstorecatalog/WriteNodeLabelApplication.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ WriteLabelResult compute(
5151
Expression nodeFilter
5252
) {
5353
var resultBuilder = WriteLabelResult
54-
.builder(graphName.getValue(), nodeLabel)
54+
.builder(graphName.value(), nodeLabel)
5555
.withConfig(configuration.toMap());
5656

5757
try (ProgressTimer ignored = ProgressTimer.start(resultBuilder::withWriteMillis)) {

applications/graph-store-catalog/src/main/java/org/neo4j/gds/applications/graphstorecatalog/WriteNodePropertiesApplication.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ NodePropertiesWriteResult write(
9090

9191
// writing
9292
NodePropertiesWriteResult.Builder builder = new NodePropertiesWriteResult.Builder(
93-
graphName.getValue(),
93+
graphName.value(),
9494
allNodeProperties
9595
);
9696
try (ProgressTimer ignored = ProgressTimer.start(builder::withWriteMillis)) {

applications/graph-store-catalog/src/main/java/org/neo4j/gds/applications/graphstorecatalog/WriteRelationshipPropertiesApplication.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ WriteRelationshipPropertiesResult compute(
6262
.build();
6363

6464
var resultBuilder = new WriteRelationshipPropertiesResult.Builder(
65-
graphName.getValue(),
65+
graphName.value(),
6666
relationshipType,
6767
relationshipProperties
6868
);

0 commit comments

Comments
 (0)