Re: Suggestion: allow accessible reflection on protected methods of exported types.

2017-01-03 Thread Michael Rasmussen
I really hope that some official API makes the cut. In the case of defineClass, java.lang.reflect.Proxy also needs this functionality, and uses its own native defineClass0 in order to inject the proxy classes into the correct class loader. I don't know if making that defineClass method accessible

Re: Valid characters in a module name

2017-01-03 Thread David M. Lloyd
On 01/01/2017 07:44 PM, Ess Kay wrote: Hi Rémi, You can update your tool to use an escape character Sure. However, can you imagine how much work it would be to update a Java source parser to allow identifiers like package and class names to contain escaped semi-colons, single quotes or double

Re: RFR: 8171855: Move package name transformations during module bootstrap into VM

2017-01-03 Thread Lois Foltan
On 1/2/2017 1:27 PM, Claes Redestad wrote: Hi, during jigsaw bootstrap, package names - represented in external form, "java.lang" - are transformed into VM internal form, "java/lang", before calling into the VM. This, however, can effectively be moved into the VM, which removes the need to gen

Re: Suggestion: allow accessible reflection on protected methods of exported types.

2017-01-03 Thread Alan Bateman
On 29/12/2016 16:24, Rafael Winterhalter wrote: : I argue that this module system should not be responsible to assert the usage of such protected methods on exported types. Such methods are not really encapsulated as they are considered official API by subclasses. Right, they are intended to be

Re: RFR: 8171855: Move package name transformations during module bootstrap into VM

2017-01-03 Thread Claes Redestad
On 01/03/2017 04:56 PM, Lois Foltan wrote: Hi Claes, I have some concerns about this change in that it will break the precedence that currently the only internal form of names that the VM deals with are binary names as they appear in class files, where the periods (.) have been replaced by

Re: RFR: 8171855: Move package name transformations during module bootstrap into VM

2017-01-03 Thread Alan Bateman
On 03/01/2017 16:44, Claes Redestad wrote: : get_module_by_package_name is only used by the whitebox API and it seems the test using this was already using internal form. JVM_GetModuleByPackageName appears to be unused. Could this be cleaned up? This may be a leftover from when we were work

Re: Suggestion: allow accessible reflection on protected methods of exported types.

2017-01-03 Thread David M. Lloyd
On 12/29/2016 01:09 PM, Jochen Theodorou wrote: On 29.12.2016 18:24, Rafael Winterhalter wrote: Hei Jochen, thank you for your feedback. I must have missed your posting, I regularly fail to follow up on the things discussed on the mailing list and its not easy to seatch for topics, sorry for tha

Re: --add-opens for entire module

2017-01-03 Thread Andrew Guibert
Alan Bateman wrote on 12/30/2016 12:23:09 AM: > From: Alan Bateman > To: Andrew Guibert/Rochester/IBM@IBMUS, jigsaw-dev d...@openjdk.java.net> > Date: 12/30/2016 12:23 AM > Subject: Re: --add-opens for entire module > > On 28/12/2016 07:30, Andrew Guibert wrote: > > > > > In the currently acce

Re: RFR: 8171855: Move package name transformations during module bootstrap into VM

2017-01-03 Thread Karen Kinnear
Claes, Thank you for all the good work you are doing identifying performance issues and making improvements. I strongly agree with Lois’ concerns. We looked at other cases in which we have an interface from java to the VM that need to pass fully qualified names, e.g. Class.forName(). The mode

Re: Suggestion: allow accessible reflection on protected methods of exported types.

2017-01-03 Thread Jochen Theodorou
On 03.01.2017 17:28, Alan Bateman wrote: On 29/12/2016 16:24, Rafael Winterhalter wrote: : I argue that this module system should not be responsible to assert the usage of such protected methods on exported types. Such methods are not really encapsulated as they are considered official API by

RE: Suggestion: allow accessible reflection on protected methods of exported types.

2017-01-03 Thread Uwe Schindler
Hi, > From: jigsaw-dev [mailto:jigsaw-dev-boun...@openjdk.java.net] On Behalf Of > Alan Bateman > On 29/12/2016 16:24, Rafael Winterhalter wrote: > > > : > > > > I argue that this module system should not be responsible to assert the > > usage of such protected methods on exported types. Such m

Re: Invoking default methods from a Proxy's InvocationHandler in JDK9

2017-01-03 Thread Mandy Chung
> On Jan 2, 2017, at 11:20 PM, Peter Levart wrote: > > Hi Matthew, > > On 01/03/2017 04:28 AM, Matthew Hall wrote: >> I'm a member of the JDBI [1] project, an open source SQL access library >> atop JDBC. >> >> A major part of our API provides implementations of declarative interfaces >> define

Re: Suggestion: allow accessible reflection on protected methods of exported types.

2017-01-03 Thread Jochen Theodorou
On 03.01.2017 18:04, David M. Lloyd wrote: [...] Here's an important point about adoption (these are my own observations, not the EG's or my employer's). One of the effects of the way Java is produced and its historical entrenchment is that no matter what happens, adoption is more or less inevit

Re: Suggestion: allow accessible reflection on protected methods of exported types.

2017-01-03 Thread Alan Bateman
On 03/01/2017 18:13, Jochen Theodorou wrote: You sound as if there are equal good alternative solutions to all these cases. For example changing the environment for a subprocess after its creation No, there is no clean solution. The only solution that does not require an opens is to do i

Re: RFR: 8171855: Move package name transformations during module bootstrap into VM

2017-01-03 Thread Claes Redestad
On 2017-01-03 19:08, Karen Kinnear wrote: Claes, Thank you for all the good work you are doing identifying performance issues and making improvements. I strongly agree with Lois’ concerns. We looked at other cases in which we have an interface from java to the VM that need to pass fully q

Proposed enhancement to Layer API

2017-01-03 Thread David M. Lloyd
This is a proposed enhancement to the Layer API, a sibling to the discussion around #NonHierarchicalLayers going on in the JPMS spec list. While discussion is ongoing, I want to ensure that there is a "real" patch somewhere out in the public that can be referenced and discussed. Essentially t

Re: Review Request: JDK-8168836 Minor clean up on warning/error messages on --add-exports and --add-reads

2017-01-03 Thread David Holmes
Hi Mandy, http://cr.openjdk.java.net/~mchung/jdk9/webrevs/8168836/webrev.00/ This patch improves the warning/error message to include the option name, emit a warning if unknown module is specified with —-patch-module be consistent with the options. Mandy As a result of this change we now

Re: Review Request: JDK-8168836 Minor clean up on warning/error messages on --add-exports and --add-reads

2017-01-03 Thread Mandy Chung
> On Jan 3, 2017, at 1:04 PM, David Holmes wrote: > > Hi Mandy, > > >> >> http://cr.openjdk.java.net/~mchung/jdk9/webrevs/8168836/webrev.00/ >> >> This patch improves the warning/error message to include the option name, >> emit a warning if unknown module is specified with —-patch-module b

Re: Valid characters in a module name

2017-01-03 Thread Ess Kay
> Java EE and JBoss Modules both allow this Two points. Firstly there is a big difference between a character being allowed and the character actually being used in practice. Are you saying that in practice anyone anywhere is putting spaces, single quotes or double quotes within a Java EE and JBoss

Re: Valid characters in a module name

2017-01-03 Thread David M. Lloyd
On 01/03/2017 03:38 PM, Ess Kay wrote: Java EE and JBoss Modules both allow this Two points. Firstly there is a big difference between a character being allowed and the character actually being used in practice. Are you saying that in practice anyone anywhere is putting spaces, single quotes or

Re: Proposed enhancement to Layer API

2017-01-03 Thread Remi Forax
I agree with all the proposed methods but the one that add a package, in my opinion, a package is part of what structurally define a module, it should not be possible to add it after the resolution algorithm. Rémi - Mail original - > De: "David M. Lloyd" > À: "jigsaw-dev" > Envoyé: Ma