How to exclude commons-logging from a scala/sbt/slf4j project?

后端 未结 4 1604
囚心锁ツ
囚心锁ツ 2020-11-30 23:54

My scala/sbt project uses grizzled-slf4j and logback. A third-party dependency uses Apache Commons Logging.

With Java/Maven, I would use jcl-over-slf4j and logback-c

4条回答
  •  不知归路
    2020-12-01 00:38

    I met the same problem before. Solved it by adding dependency like

    libraryDependencies += "foo" % "bar" % "0.7.0" exclude("commons-logging","commons-logging")
    

    or

    libraryDependencies += "foo" % "bar" % "0.7.0" excludeAll(ExclusionRule(organization = "commons-logging"))
    

提交回复
热议问题