Remove transitive classpath dependency in gradle
<p>we're running a spring-boot app with gradle.</p>

<p>In order to include the spring-boot plugin we add it as dependency:</p>

<pre><code>buildscript {
    dependencies {
        classpath("org.springframework.boot:spring-boot-gradle-plugin:1.3.2.RELEASE") 
    }
}
</code></pre>

<p>Unfortunately this plugin ships with a dependency to
<code>org.apache.logging.log4j:log4j-slf4j-impl:2.4.1</code></p>

<p>Which I'd like to exclude.</p>

<p>Already tried that by adding:</p>

<pre><code>  dependencies {
        classpath("org.springframework.boot:spring-boot-gradle-plugin:1.3.2.RELEASE") {
            exclude group: 'org.apache.logging.log4j'
        }
    }
</code></pre>

<p>Which doesn't work.</p>

<p>Also adding:</p>

<pre><code>configurations {
    classpath.exclude group: 'org.apache.logging.log4j', module: 'log4j-slf4j-impl'
}
</code></pre>

<p>Doesn't have any effect.</p>

<p>Any hint is welcome.</p>