Up Create the entity data model
Model » Create the entity data model » EDMX in Source Control

EDMX in Source Control

Last modified on August 15, 2012 17:20

The EDMX file is a precious asset that defines your Entity Data Model (EDM) and is the source for generating your entity classes.

Of course you are using a Source Control System to safeguard your application assets. The EDMX file is one of the most important application assets; please put it in source control immediately.

One less obvious but critical point: only one person at a time can work on a given EDMX file because it is almost impossible to merge changes from two versions of an EDMX file. If two people work on the same EDMX at the same time and try to commit their changes, the source control merge tool could corrupt the EDMX as it tries to merge their respective changes.

It's no big deal when this happens with code files. Firstly, merging code files usually works; it doesn't work with the EDMX ... just as it doesn't work for Web.config and App.config files.

Second, humans can read a code file and resolve conflicting text lines. A human wrote that code and can understand what it should look like. XML files such as the EDMX tend to be written by a program such as the EDM Designer. They are much more difficult to read, understand, and repair. 

Please treat the EDMX file as a binary file. Your source control system has a way of distinguishing binary files from text files. Find out how to configure it so that an EDMX is treated as a binary file.

Tags: Model EDMX EDM
Created by DevForce on March 21, 2011 18:30

This wiki is licensed under a Creative Commons 2.0 license. XWiki Enterprise 3.2 - Documentation. Copyright © 2015 IdeaBlade