开发者

EF4.1 - Is there an issue using pre-generated views with TFS team builds on separate build server?

开发者 https://www.devze.com 2023-03-10 18:50 出处:网络
I have an entity model build using EF4.1 code first, which uses a WCF Data service to expose the entities. To improve performance I have pre-generated the EF views. This works fine when I run locally,

I have an entity model build using EF4.1 code first, which uses a WCF Data service to expose the entities. To improve performance I have pre-generated the EF views. This works fine when I run locally, or if I publish the service using visual studio. However, when I use the TFS team build to create the service, I get the following error when try and access my entities via the data service:

The mapping and metadata information for EntityContainer 'X' no longer match开发者_StackOverflow社区es the information used to create the pre-generated views.

The TFS team build uses a separate build server to build the data service + entity model. The code being built is identical, the web.config + databases are also identical. This suggests that either the team build or the build server is altering either the view, the edmx file or the DbContext in some way.

Thanks in advance for any help

Ryan


This turned out to be a version mismatch between the EF4.1 dlls used on the dev servers and the dll used by the build server. For a full explanation see this thread.

EF Pre-Compiled Builds issue

0

精彩评论

暂无评论...
验证码 换一张
取 消