JAXP default implementation and JDK-8152063
David M. Lloyd
david.lloyd at redhat.com
Thu Mar 24 14:57:24 UTC 2016
On 03/24/2016 09:51 AM, Alan Bateman wrote:
>
>
> On 24/03/2016 14:29, David M. Lloyd wrote:
>>
>> Daniel, I have hacked together a way to use the system class loader
>> (which should be "good enough", I hope), but there is one further
>> problem: org.xml.sax.helpers.XMLReaderFactory does not have a factory
>> method which accepts a class loader like the others do. Any thoughts
>> on this one? It looks like it might be pretty easy to add this
>> method... but then, it's also pretty easy to just add setters to set
>> the default Class :)
>>
>>
> I hope we can avoid introducing an API to change the global/default
> implementation mid-flight. It would be attractive nuisance. It it almost
> always wrong to have a static in a system class with a strong reference
> to something that is transient. There are often security and memory
> retention issues. This becomes a lot more obvious when you have multiple
> applications running in the same VM.
OK, that's fair. Hopefully we can figure out some other way around this.
> On org.xml.sax.helpers.XMLReaderFactory then this is endorsed API. As it
> happens, it came under the spot light in a recent thread because it has
> not been converted to use ServiceLoader. I believe Joe Wang is seeing if
> this can be progressed in the upstream SAX project.
Does this mean that there will be a difference between upgradeable
modules and endorsed APIs under Jigsaw, or will all of JAXP be
fixed/locked to the platform including this API?
--
- DML
More information about the core-libs-dev
mailing list