Gradle PMD plugin *sometimes* fails to find SAXParserFactoryImpl

When running a gradle build with the PMD plugin on, this happens sometimes, but not always.

FAILURE: Build failed with an exception.

  • What went wrong: Could not resolve all dependencies for configuration ‘:subproject:pmd’. > Could not resolve net.sourceforge.pmd:pmd:5.0.2.

Required by:

XYZ:subproject:1.0b5.3625

Provider org.apache.xerces.jaxp.SAXParserFactoryImpl not found

Could not resolve org.sonatype.oss:oss-parent:7.

Provider org.apache.xerces.jaxp.SAXParserFactoryImpl not found

Provider org.apache.xerces.jaxp.SAXParserFactoryImpl not found I don’t know how to progress this transient issue. Any clues?

Question duplicated on SO: Gradle PMD plugin *sometimes* fails to find SAXParserFactoryImpl - Stack Overflow

Can you provide output of ‘gradle -v’ and the full stack trace (’-s’)? Please use GitHub Gist for the latter.

Also, can you try to run Gradle with the latest JDK 7?

My apologies. Due to a change in circumstances, I no longer have access to that environment and can’t replicate the issue.

I can tell you that it succeeded when running ‘gradlew check’ and failed when running a shell script that executed many different gradlew calls with parallel processing and daemon on… and that it failed 18 minutes or so into the build. Anything could have been happening.

Not much to go on, I know. Sorry!