如果使用企业库,log4net 是否更好登录?

发布于 2024-09-25 04:02:42 字数 153 浏览 2 评论 0原文

对于一个项目,我们正在使用 Enterprise Library 5,并将使用其中的几个块。我倾向于使用日志应用程序块,因为它内置于这个框架中。但我确实看到了很多关于 log4net 的建议,那么人们选择做什么?如果选择 log4net,为什么你选择它而不是其他一些?

谢谢。

For a project we are using Enterprise Library 5, and will be using several of the blocks. I'm inclined to use the Logging application block since its built into this framework. But I do see a lot of recommendations for log4net, so what have people chosen to do and if choosing log4net, why did you choose it over some of the others?

Thanks.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

命比纸薄 2024-10-02 04:02:42

看看这个问题: log4net vs. Nlog

投票最高的答案看起来特别相关,比较EntLib、log4net 和 NLog。

就其价值而言,我评估了 log4net 和 NLog,并选择了 NLog;我只是想要一些易于设置并且“正常工作”的东西,到目前为止 NLog 就是这样。

Take a look at this question on SO: log4net vs. Nlog

The top voted answer looks especially pertinent, comparing EntLib, log4net, and NLog.

For what it's worth, I was evaluating log4net and NLog and chose to go with NLog; I just wanted something that would be easy to set up and would "just work", and so far NLog has been that.

执手闯天涯 2024-10-02 04:02:42

我可能会选择 Enterprise Library 的记录器,因为我通常更喜欢使用一个集成库而不是使用两个单独的库。

如果您只想使用 EntLib 中的日志记录块,那么我可能会选择 log4net,但在这种情况下,无论如何您都将使用 EntLib,log4net 相对于 EntLib 的优势很小,足以不使它们成为问题同时拖入另一个依赖项。

I would probably go with Enterprise Library's logger, as I'd generally prefer one integrated library over using two separate libraries.

If you were only going to be using the logging block from EntLib, then I would probably choose log4net, but in this case, where you are going to be using EntLib anyway, the advantages of log4net over EntLib are minor enough as to not make them whilewhile to drag in another dependancy.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文