I know its a common issue to have the issue with SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/C:/Users/<name>/.gradle/caches/4.9/generated-gradle-jars/gradle-api-4.9.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/C:/Users/<name>/.gradle/caches/modules-2/files-2.1/org.apache.logging.log4j/log4j-slf4j-impl/2.2/afd596adf5086b4f4746254b25a3a4b513f1d6e4/log4j-slf4j-impl-2.2.jar!/org/slf4j/impl/StaticLoggerBinder.class]
I'm getting this error when I run a gradle build and I have applied the gradle-plugin plugin e.g. class with
import org.gradle.api.*
class CommonTestPlugin implements Plugin<Project> {
and in gradle
apply plugin: 'java-gradle-plugin'
I'm using that plugin so I can add code to create a plugin.
The error above seems to point to gradle-api as the offending dependency but I when I fired up the dependency-insight task with dependencyInsight --dependency gradle-api
it returned:
No dependencies matching given input were found in configuration ':compileClasspath'
My question is: how can I determine how to define/exclude dependency that the plugin is using? Im using things like the following, I just can't figure out how to apply that to the plugin-api
compile (group: 'com.aestasit.infrastructure.sshoogr', name: 'sshoogr', version: '0.9.26'){
// exclude this to stop warnings about multiple SLF4J bindings.
exclude group: 'ch.qos.logback', module: 'logback-classic'
}