On 29/09/2016 20:37, Rafael Winterhalter wrote:

It would be perfectly fine, in my opinion, to throw an unsupported operation exception, if the feature was unsupported. The method would primarily be used by testing code and tools.

Right, but it essentially means that anything that use Instrumentation.getInstance(...) can dynamically extend the class path, add to the boot class loader search, redefine any class or module, ... Assume the common case where there is no security manager and not using JDK-specific APIs. So I think this requires a lot of consideration before going any further - the original intention with this API is that it was for tool agents and this is why a method like the proposal method has been kept out of the API.

-Alan

Reply via email to