Cole-Greer commented on code in PR #3518:
URL: https://github.com/apache/tinkerpop/pull/3518#discussion_r3604846482
##########
gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/jsr223/GremlinScriptChecker.java:
##########
@@ -178,7 +197,9 @@ public class GremlinScriptChecker {
Pattern.compile("\\.with\\((((?:"
+ timeoutTokens + "),(?<to>\\d*)(:?L|l)?)|((?:"
+ materializePropertiesTokens +
"),[\"'](?<mp>.*?)[\"']?)|((?:"
- + requestIdTokens + "),[\"'](?<rid>.*?)[\"']))\\)");
+ + languageTokens + "),[\"'](?<lang>.*?)[\"'])|((?:"
+ + batchSizeTokens + "),(?<bs>\\d+))|((?:"
+ + bulkResultsTokens + "),(?<br>true|false)))\\)");
Review Comment:
Nit: It might be worth allowing this to be `.*` instead of `true|false` and
relying on the downstream `Boolean.parseBoolean()` to reject invalid inputs.
`parseBoolean()` is case-insensitive which I think gives nice flexibility.
The same argument could potentially be applied to the `d+` for batchSize,
although it's weaker in that case. Expanding that one to `.*` would presumably
allow for things like `+` prefixes and `L` suffixes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]