RFR: 8248131: Simplify ServicesCatalog provider handling

Claes Redestad claes.redestad at oracle.com
Tue Jun 23 16:37:20 UTC 2020


Hi Alan, Mandy,

thanks for reviewing.

I've ran all java/lang/instrument and the com/sun/tools/attach/modules
tests, as well as added tier2 to the testing mix.

/Claes

On 2020-06-23 16:09, Alan Bateman wrote:
> On 23/06/2020 09:56, Claes Redestad wrote:
>> Hi,
>>
>> the current implementation of ServicesCatalog uses an internal providers
>> method, which is only used to add ServiceProviders.
>>
>> Providing an addProviders method instead means we can streamline this,
>> to the tune of a very small startup win.
>>
>> Bug:    https://bugs.openjdk.java.net/browse/JDK-8248131
>> Webrev: http://cr.openjdk.java.net/~redestad/8248131/open.00/
>>
>> Testing: tier1
> The special casing for the providers.length == 1 case is unfortunate but 
> otherwise looks good to me.
> 
> Can you make sure to run the jdk_instrument test group and the 
> com/sun/tools/attach/modules tests as the changed code is also executing 
> redefining a module to implement new providers, also when attach 
> mechanism is use to load the jdk.management and jdk.attach modules are 
> loaded into a running VM.
> 
> -Alan.


More information about the core-libs-dev mailing list