Join GitHub today
Prevent Quartz XSD from being fetched from the Internet [SPR-13706] #18281
Quartz offer classloading spi through the org.quartz.spi.ClassLoadHelper interface.
Spring implements ClassLoadHelper in the ResourceLoaderClassLoadHelper which is use as the default Quartz value for 'org.quartz.scheduler.classLoadHelper.class'.
When I'm deploying my application inside JBoss EAP 6.1 and/or Wildfly 8.2.1.Final, the "job_scheduling_data_2_0.xsd" is getting hit from the Internet because it failed to fetch it properly from the classpath.
XMLSchedulingDataProcessorPlugin::processFile(JobFile) -> XMLSchedulingDataProcessor(classLoadHelper) -> resolveSchemaSource()
by enabling the org.quartz.xml.XMLSchedulingDataProcessor logger you'll see that inside a container the "Unable to load local schema packaged in quartz distribution jar" trace will appear.
Here's our temporary workaround which involve of prefixing "classpath:" to any XSD resource:
This workaround always retreive the XSD resource properly from the classpath. This work, though, this is definitely ugly.
I would suggest instead of our ugly workaround to simply change the Spring implementation to:
Let me know if I've miss something.
Affects: 3.2.16, 4.2.2
Backported to: 3.2.17
Stéphane Nicoll commented
That's not what I experience with a vanilla setup. We have an integration test with no special configuration and a lookup for
Sven-Erik Petermann commented
I can confirm the issue for Spring 4.2.4, Quartz 2.2.2.
This is the top of the stack trace:
Juergen Hoeller commented
Thanks for raising this! Indeed, we should not rely on the