App_Global.asax.compiled和App_Global.asax.dll失踪?的WebAPI .NET 4.5的项目 [英] App_Global.asax.compiled and App_Global.asax.dll missing? WebApi .NET 4.5 project

查看:2185
本文介绍了App_Global.asax.compiled和App_Global.asax.dll失踪?的WebAPI .NET 4.5的项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我们建设一个简单的API使用的WebAPI,我们有我们的任何项目确实,但是我无法找到任何这样的资源,可以解释以下行为问题的公平份额的冒险:

During our adventures of building a 'simple' API using WebAPI we've had our fair share of issues as any project does, however I am unable to find any such resource that can explain the following behavior:



这个问题似乎与发布命令,明确了precompile选项。


The issue seems to be related to the "Publish" command, specifically the "Precompile" option.

    当通过IIS防爆preSS运行,我们认为没有问题的。
    When running via IIS Express, we see no issues at all.
    如果我们发布一次,它没有包括App_Global.asax.compiled&App_Global.asax.dll bin目录。如果它被更新应用程序的现有实例,它实际上将删除现有两个文件。


    注:发生这种情况无论WebPublish或者文件系统的发布
    http://i.stack.imgur.com/etSZt.jpg
    If we publish once, it fails to include the App_Global.asax.compiled & App_Global.asax.dll in the bin directory. If it is updating an existing instance of the application, it will actually delete the existing two files.

    Note: This Happens regardless of WebPublish or FileSystem Publish
    ( http://i.stack.imgur.com/etSZt.jpg )
    此行为导致在加载404.0错误到IIS,而不是我们预期的201。
    This behavior is causing 404.0 Errors upon loading to IIS, instead of our expected 201.
    但是,如果我发布了第二次没有改变previous配置文件/配置,它增加了两回。


    http://i.stack.imgur.com/oNCKr.jpg
    However, if I publish a second time no changes to the previous profile/configuration, it adds the two back.

    ( http://i.stack.imgur.com/oNCKr.jpg )
    有一段时间,我们还以为是权限问题,并没有看到一致的行为。这发生在我们所有具有相同行为的开发机器。
    For a while, we thought it was permissions issues, and weren't seeing consistent behavior. This happens on all of our development machines with the same behavior.
    我们已经看到了关于神秘行为的帖子,但是从我们的分析,这是问题的根源。
    We've seen posts regarding mysterious behavior, but from our analysis, this is the root of the problem.

推荐答案

只想让大家知道我的问题得到解决。

Just wanted to let everyone know that my problem was solved.

这是一个病毒扫描程序扫描为precompiling新创建的临时目录,实际上锁定问题的文件的问题。

This was an issue with a virus scanner scanning the newly created temp directory for precompiling and actually locking the files in question.

因此​​,如果任何人有像这样的问题,并正在运行的防病毒(尤其是企业级):

So if anyone has issues such as this and is running any antivirus (especially enterprise level):





  • 检查您的防病毒是锁定的文件。

  •     
  • 关闭所有compsec扫描实用程序和一个打开一个孤立,这是造成问题。

这篇关于App_Global.asax.compiled和App_Global.asax.dll失踪?的WebAPI .NET 4.5的项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆