本文介绍了@ServiceHost调试="真" - 性能损失?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有在SVC文件设置调试=真的性能损失?它是足够的显著,以保证在生产环境中,它设置为假?

Is there a performance penalty of setting Debug="true" in the svc file? Is it significant enough to warrant setting it to "false" in a production environment?

%@ ServiceHost Language="C#" **Debug="true"** Service="AwesomeService" %>

感谢

推荐答案

在你的SVC的文件,如果你写你的服务为在线 code或实施服务 APP_ code 文件夹,使调试模式下,它会影响性能

In your ".svc" file, if you are writing your service as inline code, or implementing service in "App_Code" folder and enabling debug mode, it will impact the performance.

一般情况下,始终设置调试=假您部署到生产环境之前。如果启用了调试模式,应用程序的性能会降低。

Generally, always set debug="false" before you deploy to production. If debug mode is enabled, the performance of your application can be decreased.

在发行模式下,调试符号不烤成的组装,因此  使用Visual Studio .NET或其他来源的code不能调试它  调试器。什么是酷的是,code为在此也进行了优化  建立操作。

这篇关于@ServiceHost调试="真" - 性能损失?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-22 21:53
查看更多