[ 
https://issues.apache.org/jira/browse/TINKERPOP-1697?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16157218#comment-16157218
 ] 

stephen mallette commented on TINKERPOP-1697:
---------------------------------------------

I'm not sure I can implement this as you would like. Gremlin Server uses 
reflection to detect the builder methods to call on the plugin when it is 
constructed. To do that it has to make some assumption that the user knows how 
to configure the plugin properly. Passing in an empty string for an integer 
just doesn't work with a reflection based approach - at least not without a lot 
of extra processing and further assumptions from the server. 

I think that the way to think about configuring plugins is to:

1. assume they have decent defaults (which they do afaik)
2. only set the value in the config if you intend to change something - i think 
"null" as a value may be a valid setting in some cases and not an indicator of 
a no-op or a default setting.

Short of building out a much more advanced configuration system for the plugins 
I don't really see a way to make this work and for the effort involved it 
doesn't seem worth it. I'll leave this open for a bit in case anyone has 
further comment or other ideas, but I'm inclined to close this.

> Allow null values in config
> ---------------------------
>
>                 Key: TINKERPOP-1697
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP-1697
>             Project: TinkerPop
>          Issue Type: Improvement
>          Components: server
>    Affects Versions: 3.3.0
>            Reporter: Xian Yi Teng
>
> Under 
> scriptEngines/gremlin-groovy/plugins/org.apache.tinkerpop.gremlin.groovy.jsr223.GroovyCompilerGremlinPlugin:
> extensions: null (x)
> extensions: (x)
> extensions: "" (/)
> timedInterrupt: "" (x)
> timedInterrupt: (x)
> timedInterrupt: 0 (/)
> Would be nice to streamline these. 



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to