RFR (JAXP) 8028822 : Error in the documentation for newFactory method of the javax.xml.stream factories

huizhe wang huizhe.wang at oracle.com
Tue Nov 26 22:27:57 UTC 2013

On 11/26/2013 1:59 PM, roger riggs wrote:
> Hi,
> I looked at that twice also.    java.time had a similar situation.
> To get to the TCCL you need to call ServiceLoader.load(type).
> The FactoryFinder:348 findServiceProvider method should test if cl == 
> null and call the original ServiceLoader function.

Yes. I forgot that part. load(service, loader) treats null as the system 
class loader was one of the topics in the discussion of the spec.


> Roger
> On 11/26/2013 4:37 PM, Alan Bateman wrote:
>> On 26/11/2013 18:38, huizhe wang wrote:
>>> Hi all,
>>> Here's revised webrev, as Alan suggested, including the implementation.
>>> http://cr.openjdk.java.net/~joehw/jdk8/jaxp16MR/8028822/webrev/
>> So is this handling the null case correctly? It is spec'ed to use the 
>> TCCL but it looks like it's going through to ServiceLoader.load where 
>> null means the system class loader. Maybe this needs to wait for 
>> tests as that it really the only way to check this.
>> -Alan

More information about the core-libs-dev mailing list