Skip to content

Commit cce109a

Browse files
committedJan 8, 2025
PR updates
1 parent 15b97bc commit cce109a

File tree

2 files changed

+2
-7
lines changed

2 files changed

+2
-7
lines changed
 

‎core/src/main/java/apoc/cypher/Timeboxed.java

+1-6
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ public Stream<CypherStatementMapResult> runTimeboxed(
7070
@Name(value = "statement", description = "The Cypher statement to run.") String cypher,
7171
@Name(value = "params", description = "The parameters for the given Cypher statement.")
7272
Map<String, Object> params,
73-
@Name(value = "timeout", description = "The maximum time the statement can run for.") long timeout,
73+
@Name(value = "timeout", description = "The maximum time, in milliseconds, the statement can run for.") long timeout,
7474
@Name(
7575
value = "config",
7676
defaultValue = "{}",
@@ -83,11 +83,6 @@ public Stream<CypherStatementMapResult> runTimeboxed(
8383
boolean failOnError = toBoolean(config.get("failOnError"));
8484
boolean appendStatusRow = toBoolean(config.get("appendStatusRow"));
8585

86-
// Check the query is valid before trying to run it
87-
if (failOnError) {
88-
Util.validateQuery(db, cypher);
89-
}
90-
9186
// run query to be timeboxed in a separate thread to enable proper tx termination
9287
// if we'd run this in current thread, a tx.terminate would kill the transaction the procedure call uses itself.
9388
pools.getDefaultExecutorService().submit(() -> {

‎core/src/test/resources/procedures/common/procedures.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1794,7 +1794,7 @@
17941794
"type" : "MAP"
17951795
}, {
17961796
"name" : "timeout",
1797-
"description" : "The maximum time the statement can run for.",
1797+
"description" : "The maximum time, in milliseconds, the statement can run for.",
17981798
"isDeprecated" : false,
17991799
"type" : "INTEGER"
18001800
},

0 commit comments

Comments
 (0)