RFR 8168615: JShell API: jdk.jshell.spi should be a pluggable ServiceLoader SPI

Jan Lahoda jan.lahoda at oracle.com
Tue Dec 6 18:14:47 UTC 2016


A few comments:
-the -X help will (in my understanding) produce this:
+\    --execution <spec>                 Specify an alternate execution 
engine.\n\
+\                                        Where <spec> is an 
ExecutionControldProvider spec.\n\
+\                                        See jdk.jshell.spi\n\

As this is a user-level help (although a very experienced user, 
presumably), it would be better I think to provide some details - e.g. 
the grammar for the spec; known provider; and ideally, parameters of the 
known providers

-I would reorganize the rules in the spec grammar to go from the top down:
+     * spec := name : params
+     *       | name
+     * name := id
+     * params := param , params
+     *        | param
+     *        |
+     * param := id ( value )

(might be also good to say what is "id")

-ExecutionControlProvider.logMessages seems weird. Is it used outside of 
tests?

-after this patch, both the ExecutionControls and their Providers are 
public - is that desirable? Is there a usecase for the client to 
call/instantiate the Providers directly without going through the 
ServiceLoader?

Jan

On 2.12.2016 08:48, Robert Field wrote:
> Please review...
>
> Bug:
>
>       https://bugs.openjdk.java.net/browse/JDK-8168615
>
>
> Webrev:
>
>      http://cr.openjdk.java.net/~rfield/8168615v0.webrev/
>
> Thanks,
> Robert
>


More information about the kulla-dev mailing list