问题描述
问题是,需要更多的45秒内按F5,直到网页渲染的点的项目 - 与绝大部分的时间到来后:
The problem is a project that takes more that 45 seconds from the point of hitting F5 until the webpage is rendered - with the vast bulk of the time coming after:
'iisexpress.exe' (CLR v4.0.30319: /LM/W3SVC/22/ROOT-1-130320809789454211): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Microsoft.Build.Framework\v4.0_4.0.0.0__b03f5f7f11d50a3a\Microsoft.Build.Framework.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
和前
'iisexpress.exe' (CLR v4.0.30319: /LM/W3SVC/22/ROOT-1-130320809789454211): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Data.Entity\v4.0_4.0.0.0__b77a5c561934e089\System.Data.Entity.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
现在用VS2013编译一个4.5的目标项目,并使用EF5周四EF6.0.3清洁看到相同的行为和建造时间接近瞬时的。
Am using VS2013 compiling a 4.5 targeted project and have seen the same behavior using EF5 thur EF6.0.3 Clean and Build time are near instantaneous.
我通过逆向工程工具生成的code首先和波苏斯工作。中等复杂(一对多对许多对象),但相当小 - 小于两打实体
I'm working with Code First and POCOs that were generated by the Reverse Engineer tool. Moderately complex (a couple many-to-many objects) but fairly small - less than two dozen entities.
我twiddled与上下文的配置ProxyCreationEnabled并与建造时间没有影响LazyLoadingEnabled。我已经删除了几个许多一对多的关系 - 再次,没有效果。
I've twiddled with the context's configuration ProxyCreationEnabled and LazyLoadingEnabled with no effect on build time. I've removed a couple of the many-to-many relations - again, no effect.
我已经装了几个样品EF项目进行比较,但我没有看到正在使用的System.Data.Entity.dll。是,并且可能与该数据库服务器正在使用的项目?而不是使用VS的的LocalDB,我开发的数据库是SQL 2012开发版 - 只是因为我preFER看/检查输出SSMS
I've loaded a couple sample EF projects to compare but I'm not seeing the System.Data.Entity.dll being used. Is that perhaps related to the db server being used by the project? Rather than using VS's LocalDb, my dev database is SQL 2012 Dev edition - just because I prefer watching/checking output with SSMS.
我在切换到的LocalDB做了一些初步尝试,但遇到不相关的错误,并在同一地点相同的延迟。快乐,如果它认为relavent俯冲下来的兔子洞。
I've made some initial attempts at switching to LocalDb but encounter unrelated errors and the same delay at the same place. Happy to dive down that rabbit hole if it's deemed relavent.
我没有什么没有经验混日子的GAC或故障排除的框架,所以如果有什么东西通过的任何更深层次的检查中了解我的系统的内部结构,请慢慢讲,如果一个小的孩子。
I have little to no experience mucking about the GAC or troubleshooting the innards of the framework so if there's something to be learned about my system via deeper inspection of either, please speak slowly as if to a small child.
谢谢了
推荐答案
我通过我的web.config加强,发现我不是少数几个板块 - 注释出来编译时间缩短了一半后
I stepped through my web.config and found a couple sections that I'm not - after commenting them out the compile time was cut in half.
这篇关于非常长的编译时间,实体框架项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!