NoClassDefFoundError:带有回送的org/slf4j/LoggerFactory

编程入门 行业动态 更新时间:2024-10-24 04:41:18
本文介绍了NoClassDefFoundError:带有回送的org/slf4j/LoggerFactory的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

请帮助

在过去的几天里,我一直在尝试让Logback 1.1.3与我的Bukkit插件配合使用.作为参考,我的pom.xml包括以下几行:

For the past couple of days I have been trying to get Logback 1.1.3 to work with my Bukkit plugin. For reference my pom.xml includes these lines:

<dependency> <groupId>ch.qos.logback</groupId> <artifactId>logback-core</artifactId> <version>1.1.3</version> </dependency> <dependency> <groupId>ch.qos.logback</groupId> <artifactId>logback-classic</artifactId> <version>1.1.3</version> </dependency>

"Maven依赖关系"下列出了以下jar:

And the following jars are listed under "Maven Dependencies":

  • logback-core-1.1.3.jar
  • logback-classic-1.1.3,jar
  • slf4j-api-1.7.7.jar(突然出现)

可以在此处找到服务器控制台生成的堆栈跟踪(MoneyDrops.java的第29行是: private static final Logger LOGGER = LoggerFactory.getLogger("MoneyDropsLogger");).

The stacktrace that the server console produces can be found here (line 29 of MoneyDrops.java is: private static final Logger LOGGER = LoggerFactory.getLogger("MoneyDropsLogger");).

我也搜索了stackoverflow,但是所有答案都表明我需要提供一个使用SLF4J api的实现(例如log4j),但是据我了解,logback本机实现了该api,但我没有需要另一个jar文件.

I have also searched through stackoverflow but all the answers suggest that I need to provide an implementation that use the SLF4J api (such as log4j), however, it is to my understanding that logback natively implements the api and that I do not need another jar file.

任何帮助将不胜感激.

推荐答案

谢谢大家的帮助!我得出的结论是,无论如何我实际上都不需要登录插件(它并不那么繁重),而是选择将其完全删除并依靠Bukkit logger代替.再次感谢大家的帮助.

Thank you all for your help! I have concluded that I do not actually need logging in my plugin anyway (it is not that heavy) and have opted to remove it completely and rely on the Bukkit logger instead. Again, thank you all for your help.

更多推荐

NoClassDefFoundError:带有回送的org/slf4j/LoggerFactory

本文发布于:2023-11-14 10:16:22,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1586947.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:回送   NoClassDefFoundError   org   LoggerFactory   slf4j

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!