title: NoSuchMethodError with slfj4
body: <p>I'm trying to use Solr with slfj4 and logback, and when I shut down Solr with CTRL+C, I get this error:</p>
  
  <pre><code> java.lang.NoSuchMethodError: org.slf4j.spi.LocationAwareLogger.log(Lorg/slf4j/Marker;Ljava/lang/String;ILjava/lang/String;[Ljava/lang/Object;Ljava/lang/Throwable;)V
  </code></pre>
  
  <p>This doesn't happen during compile time.</p>
  
  <p>I've checked the method signature for org.slf4j.spi.LocationAwareLogger.log in version 1.6.4, and it seems to be correct:</p>
  
  <pre><code>  public void log(Marker marker, String fqcn, int level, String message, Object[] argArray, Throwable t);
  </code></pre>
  
  <p><strong>Complete stack trace:</strong></p>
  
  <pre><code>2012-04-27 12:02:09.806 [Shutdown] ERROR o.a.s.h.c.HttpShardHandlerFactory - java.lang.NoSuchMethodError: org.slf4j.spi.LocationAwareLogger.log(Lorg/slf4j/Marker;Ljava/lang/String;ILjava/lang/String;[Ljava/lang/Object;Ljava/lang/Throwable;)V
          at org.apache.commons.logging.impl.SLF4JLocationAwareLog.debug(SLF4JLocationAwareLog.java:133
  )
          at org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager.shutdown(ThreadSafeClientConnManager.java:282)
          at org.apache.solr.handler.component.HttpShardHandlerFactory.close(HttpShardHandlerFactory.java:172)
          at org.apache.solr.core.CoreContainer.shutdown(CoreContainer.java:599)
          at org.apache.solr.servlet.SolrDispatchFilter.destroy(SolrDispatchFilter.java:124)
          at org.mortbay.jetty.servlet.FilterHolder.destroyInstance(FilterHolder.java:127)
          at org.mortbay.jetty.servlet.FilterHolder.doStop(FilterHolder.java:107)
          at org.mortbay.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:76)
          at org.mortbay.jetty.servlet.ServletHandler.doStop(ServletHandler.java:176)        at org.mortbay.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:76)
          at org.mortbay.jetty.handler.HandlerWrapper.doStop(HandlerWrapper.java:142)
          at org.mortbay.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:76)
          at org.mortbay.jetty.handler.HandlerWrapper.doStop(HandlerWrapper.java:142)        at org.mortbay.jetty.servlet.SessionHandler.doStop(SessionHandler.java:125)
          at org.mortbay.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:76)
          at org.mortbay.jetty.handler.HandlerWrapper.doStop(HandlerWrapper.java:142)
          at org.mortbay.jetty.handler.ContextHandler.doStop(ContextHandler.java:592)        at org.mortbay.jetty.webapp.WebAppContext.doStop(WebAppContext.java:537)
          at org.mortbay.jetty.plugin.Jetty6PluginWebAppContext.doStop(Jetty6PluginWebAppContext.java:1
  23)
          at org.mortbay.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:76)        at org.mortbay.jetty.handler.HandlerCollection.doStop(HandlerCollection.java:169)
          at org.mortbay.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:76)
          at org.mortbay.jetty.handler.HandlerCollection.doStop(HandlerCollection.java:169)
          at org.mortbay.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:76)        at org.mortbay.jetty.handler.HandlerWrapper.doStop(HandlerWrapper.java:142)
          at org.mortbay.jetty.Server.doStop(Server.java:283)
          at org.mortbay.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:76)
          at org.mortbay.jetty.Server$ShutdownHookThread.run(Server.java:561)
  </code></pre>
  
  <p><strong>My <code>pom.xml</code>:</strong></p>
  
  <pre><code>&lt;project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
  
      &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
      &lt;groupId&gt;com.shutterstock&lt;/groupId&gt;
      &lt;artifactId&gt;solr&lt;/artifactId&gt;
      &lt;version&gt;0.0.1&lt;/version&gt;
      &lt;packaging&gt;war&lt;/packaging&gt;
      &lt;name&gt;Apache Solr Web Application&lt;/name&gt;
      &lt;properties&gt;
          &lt;solr.build.dir&gt;../build/solr-maven&lt;/solr.build.dir&gt;
          &lt;project.build.sourceEncoding&gt;UTF-8&lt;/project.build.sourceEncoding&gt;
      &lt;/properties&gt;
  
      &lt;repositories&gt;
          &lt;repository&gt;
              &lt;id&gt;central&lt;/id&gt;
              &lt;name&gt;Maven Repository Switchboard&lt;/name&gt;
              &lt;layout&gt;default&lt;/layout&gt;
              &lt;url&gt;http://repo1.maven.org/maven2&lt;/url&gt;
          &lt;/repository&gt;
          &lt;repository&gt;
              &lt;id&gt;trunk&lt;/id&gt;
              &lt;name&gt;solr snapshots&lt;/name&gt;
              &lt;url&gt;http://repository.apache.org/snapshots&lt;/url&gt;
          &lt;/repository&gt;
          &lt;repository&gt;
              &lt;id&gt;ubercraft&lt;/id&gt;
              &lt;name&gt;ubercraft statsd packages&lt;/name&gt;
              &lt;url&gt;https://oss.sonatype.org/content/repositories/releases&lt;/url&gt;
          &lt;/repository&gt;
      &lt;/repositories&gt;
  
      &lt;pluginRepositories&gt;
          &lt;pluginRepository&gt;
              &lt;id&gt;central&lt;/id&gt;
              &lt;name&gt;Maven Plugin Repository&lt;/name&gt;
              &lt;url&gt;http://repo1.maven.org/maven2&lt;/url&gt;
              &lt;layout&gt;default&lt;/layout&gt;
          &lt;/pluginRepository&gt;
      &lt;/pluginRepositories&gt;
  
      &lt;dependencies&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.solr&lt;/groupId&gt;
              &lt;artifactId&gt;solr&lt;/artifactId&gt;
              &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
              &lt;type&gt;war&lt;/type&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.solr&lt;/groupId&gt;
              &lt;artifactId&gt;solr-core&lt;/artifactId&gt;
              &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
              &lt;exclusions&gt;
                  &lt;exclusion&gt;
                      &lt;artifactId&gt;slf4j-api&lt;/artifactId&gt;
                      &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
                  &lt;/exclusion&gt;
                  &lt;exclusion&gt;
                      &lt;artifactId&gt;jcl-over-slf4j&lt;/artifactId&gt;
                      &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
                  &lt;/exclusion&gt;
                  &lt;exclusion&gt;
                      &lt;artifactId&gt;slf4j-jdk14&lt;/artifactId&gt;
                      &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
                  &lt;/exclusion&gt;
              &lt;/exclusions&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.solr&lt;/groupId&gt;
              &lt;artifactId&gt;solr-analysis-extras&lt;/artifactId&gt;
              &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
              &lt;exclusions&gt;
                  &lt;exclusion&gt;
                      &lt;artifactId&gt;slf4j-api&lt;/artifactId&gt;
                      &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
                  &lt;/exclusion&gt;
              &lt;/exclusions&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.solr&lt;/groupId&gt;
              &lt;artifactId&gt;solr-commons-csv&lt;/artifactId&gt;
              &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
              &lt;exclusions&gt;
                  &lt;exclusion&gt;
                      &lt;artifactId&gt;slf4j-api&lt;/artifactId&gt;
                      &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
                  &lt;/exclusion&gt;
              &lt;/exclusions&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.lucene&lt;/groupId&gt;
              &lt;artifactId&gt;lucene-core&lt;/artifactId&gt;
              &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
              &lt;type&gt;jar&lt;/type&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.lucene&lt;/groupId&gt;
              &lt;artifactId&gt;lucene-spatial&lt;/artifactId&gt;
              &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.lucene&lt;/groupId&gt;
              &lt;artifactId&gt;lucene-queryparser&lt;/artifactId&gt;
              &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.lucene&lt;/groupId&gt;
              &lt;artifactId&gt;lucene-analyzers-common&lt;/artifactId&gt;
              &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.lucene&lt;/groupId&gt;
              &lt;artifactId&gt;lucene-queries&lt;/artifactId&gt;
              &lt;version&gt;4.0-SNAPSHOT&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
              &lt;artifactId&gt;slf4j-api&lt;/artifactId&gt;
              &lt;version&gt;1.6.4&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;ch.qos.logback&lt;/groupId&gt;
              &lt;artifactId&gt;logback-classic&lt;/artifactId&gt;
              &lt;version&gt;0.9.22&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.ubercraft.statsd&lt;/groupId&gt;
              &lt;artifactId&gt;statsd-over-slf4j&lt;/artifactId&gt;
              &lt;version&gt;1.0.0&lt;/version&gt;
          &lt;/dependency&gt;
      &lt;/dependencies&gt;
  
      &lt;build&gt;
          &lt;plugins&gt;
              &lt;plugin&gt;
                  &lt;groupId&gt;org.mortbay.jetty&lt;/groupId&gt;
                  &lt;artifactId&gt;maven-jetty-plugin&lt;/artifactId&gt;
                  &lt;version&gt;6.1.26&lt;/version&gt;
              &lt;/plugin&gt;
          &lt;/plugins&gt;
      &lt;/build&gt;
  
  &lt;/project&gt;
  </code></pre>
  
  <p><strong>Maven dependency tree:</strong></p>
  
  <pre><code>$ mvn dependency:tree
  [INFO] Scanning for projects...
  [INFO]                                                                         
  [INFO] ------------------------------------------------------------------------
  [INFO] Building Apache Solr Web Application 0.0.1
  [INFO] ------------------------------------------------------------------------
  [INFO] 
  [INFO] --- maven-dependency-plugin:2.1:tree (default-cli) @ solr ---
  [INFO] com.shutterstock:solr:war:0.0.1
  [INFO] +- org.apache.solr:solr:war:4.0-SNAPSHOT:compile
  [INFO] +- org.apache.solr:solr-core:jar:4.0-SNAPSHOT:compile
  [INFO] |  +- org.apache.solr:solr-solrj:jar:4.0-SNAPSHOT:compile
  [INFO] |  |  \- org.apache.zookeeper:zookeeper:jar:3.3.4:compile
  [INFO] |  +- org.apache.lucene:lucene-analyzers-kuromoji:jar:4.0-SNAPSHOT:compile
  [INFO] |  +- org.apache.lucene:lucene-analyzers-morfologik:jar:4.0-SNAPSHOT:compile
  [INFO] |  |  \- org.carrot2:morfologik-polish:jar:1.5.2:compile
  [INFO] |  |     \- org.carrot2:morfologik-stemming:jar:1.5.2:compile
  [INFO] |  |        \- org.carrot2:morfologik-fsa:jar:1.5.2:compile
  [INFO] |  +- org.apache.lucene:lucene-analyzers-phonetic:jar:4.0-SNAPSHOT:compile
  [INFO] |  +- org.apache.lucene:lucene-highlighter:jar:4.0-SNAPSHOT:compile
  [INFO] |  +- org.apache.lucene:lucene-memory:jar:4.0-SNAPSHOT:compile
  [INFO] |  +- org.apache.lucene:lucene-misc:jar:4.0-SNAPSHOT:compile
  [INFO] |  +- org.apache.lucene:lucene-suggest:jar:4.0-SNAPSHOT:compile
  [INFO] |  +- org.apache.lucene:lucene-grouping:jar:4.0-SNAPSHOT:compile
  [INFO] |  +- commons-codec:commons-codec:jar:1.6:compile
  [INFO] |  +- commons-fileupload:commons-fileupload:jar:1.2.1:compile
  [INFO] |  +- org.apache.httpcomponents:httpmime:jar:4.1.3:compile
  [INFO] |  |  +- org.apache.httpcomponents:httpcore:jar:4.1.4:compile
  [INFO] |  |  \- commons-logging:commons-logging:jar:1.1.1:compile
  [INFO] |  +- commons-io:commons-io:jar:2.1:compile
  [INFO] |  +- commons-lang:commons-lang:jar:2.6:compile
  [INFO] |  +- com.google.guava:guava:jar:r05:compile
  [INFO] |  +- org.codehaus.woodstox:wstx-asl:jar:3.2.7:runtime
  [INFO] |  \- org.apache.httpcomponents:httpclient:jar:4.1.3:compile
  [INFO] +- org.apache.solr:solr-analysis-extras:jar:4.0-SNAPSHOT:compile
  [INFO] |  +- org.apache.lucene:lucene-analyzers-icu:jar:4.0-SNAPSHOT:compile
  [INFO] |  |  \- com.ibm.icu:icu4j:jar:4.8.1.1:compile
  [INFO] |  +- org.apache.lucene:lucene-analyzers-smartcn:jar:4.0-SNAPSHOT:compile
  [INFO] |  \- org.apache.lucene:lucene-analyzers-stempel:jar:4.0-SNAPSHOT:compile
  [INFO] +- org.apache.solr:solr-commons-csv:jar:4.0-SNAPSHOT:compile
  [INFO] +- org.apache.lucene:lucene-core:jar:4.0-SNAPSHOT:compile
  [INFO] +- org.apache.lucene:lucene-spatial:jar:4.0-SNAPSHOT:compile
  [INFO] |  \- com.spatial4j:spatial4j:jar:0.2:compile
  [INFO] +- org.apache.lucene:lucene-queryparser:jar:4.0-SNAPSHOT:compile
  [INFO] |  \- org.apache.lucene:lucene-sandbox:jar:4.0-SNAPSHOT:compile
  [INFO] |     \- jakarta-regexp:jakarta-regexp:jar:1.4:compile
  [INFO] +- org.apache.lucene:lucene-analyzers-common:jar:4.0-SNAPSHOT:compile
  [INFO] +- org.apache.lucene:lucene-queries:jar:4.0-SNAPSHOT:compile
  [INFO] +- org.slf4j:slf4j-api:jar:1.6.4:compile
  [INFO] +- ch.qos.logback:logback-classic:jar:0.9.22:compile
  [INFO] |  \- ch.qos.logback:logback-core:jar:0.9.22:compile
  [INFO] \- org.ubercraft.statsd:statsd-over-slf4j:jar:1.0.0:compile
  [INFO] ------------------------------------------------------------------------
  [INFO] BUILD SUCCESS
  [INFO] ------------------------------------------------------------------------
  [INFO] Total time: 2.383s
  [INFO] Finished at: Fri Apr 27 12:14:43 EDT 2012
  [INFO] Final Memory: 10M/482M
  [INFO] ------------------------------------------------------------------------
  </code></pre>