看起来您忘记使用 IIS7 向 Windsor Castle 注册 http 模块

编程入门 行业动态 更新时间:2024-10-23 13:26:44
本文介绍了看起来您忘记使用 IIS7 向 Windsor Castle 注册 http 模块的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我在我的一个 MVC 项目中使用 Windsor DI 框架.当我尝试从 Visual Studio 2008 运行时,该项目运行良好.

I am using windsor DI framework in one of my MVC project. The project works fine when I tried to run from Visual Studio 2008.

但是当我尝试运行在 IIS7 中创建应用程序的项目时,我收到以下错误消息:

But when i tried to run the project creating an application in IIS7 then I recieved the following error message:

您好像忘记注册 http 模块了Castle.MicroKernel.Lifestyle.PerWebRequestLifestyleModule Add '<addname="PerRequestLifestyle"type="Castle.MicroKernel.Lifestyle.PerWebRequestLifestyleModule,Castle.MicroKernel"/>'到您的部分web.config

Looks like you forgot to register the http module Castle.MicroKernel.Lifestyle.PerWebRequestLifestyleModule Add '<add name="PerRequestLifestyle" type="Castle.MicroKernel.Lifestyle.PerWebRequestLifestyleModule, Castle.MicroKernel" />' to the section on your web.config

但是这个模块已经存在于 web.config 文件的 httpmodule 部分.

But this module already exists in the httpmodule section of web.config file.

有谁知道我必须做些什么来消除这个问题.

Does anyone know what I have to do to eliminate this problem.

推荐答案

尝试将其添加到 system.webServer 部分吗?

Try adding it to the system.webServer section as well?

<configuration> <system.web> <httpModules> <add name="PerRequestLifestyle" type="..." /> </httpModules> </system.web> <system.webServer> <modules> <add name="PerRequestLifestyle" type="..." /> </modules> </system.webServer> </configuration>

更多推荐

看起来您忘记使用 IIS7 向 Windsor Castle 注册 http 模块

本文发布于:2023-11-17 03:02:54,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1608574.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:模块   Windsor   http   Castle

发布评论

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

>www.elefans.com

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