ELMAH on ASP.NET vNext?

别来无恙 提交于 2019-12-12 08:18:47

问题


Is it possible to configure ELMAH with ASP.NET vNext? If so, how?

I am lost as to where even start, given there's not even a web.config anymore. If anyone has or can figure it out, please share with us.

Thank you


回答1:


ELMAH does not work with ASP.NET 5 because ELMAH (given its name) is based on ASP.NET 4.x's Modules and Handlers (the "MAH" of "ELMAH").

In ASP.NET 5 the replacement for modules and handlers is called middleware.

There is a prototype in ASP.NET 5 called "ELM" (Error Logging Middleware) that has some features similar to ELMAH. You can check out a sample here: https://github.com/aspnet/Entropy/tree/dev/samples/Logging.Elm



来源:https://stackoverflow.com/questions/28907017/elmah-on-asp-net-vnext

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!