• Object Service (ObjectContext, ObjectQuery and EntityObject)

    The core objects of object service is ObjectContext and ObjectQuery and EntityObject. You can think of ObjectContext as entity repository. The repository is responsible to Insert/Update/Delete/Select entity.

  • Domain-Driven Development with EF v1

    Entity Framework version 1 is data-centric in the features it implements. Domain-driven development begins with the model, not the database. Many developers who embrace the tenets of domain-driven design will find the Entity Framework to be too restrictive. However, some of the advocates of this point of view are working with the Entity Framework team to enable version 2 to expand its capabilities so that you can use it with this approach.

  • Challenges with Change Tracking Distributed Applications

    To put it mildly, using the Entity Framework in distributed applications can be challenging when it comes to the change tracking performed by Object Services, because the change-tracking information is not stored in the entities and instead is maintained by a separate set of Object Services objects. When an entity is transferred across a process, it is disconnected from the object that contains its change-tracking information. Those objects that own the tracking data are not serializable, so they can't easily be shipped across to the new process along with the entities. Therefore, when the entities arrive at the new process, they have no idea whether they are new or preexisting, or whether they have been edited or marked for deletion. There's no way to simply use the ObjectContext's default method for saving changes to the database without doing additional work.

  • Limitation of Entity Data Model Designer

    The disigner does not support all the features of the EDM. With some of less frequently used EDM features, you will have to work with the XML after all.

  • Entity in Entity Framework

    Entities are not the same as objects. Entities define the schema of an object, but not its behavior. So, an entity is something like the schema of a table in your database, except that it describes the schema of your business objects. Entity Framework is to build a conceptual model, entity data model from database schema, but not only database schema.

    An EDM is a client-side data model and it is the core of the Entity Framework. It is not the same as the database model, that belongs to the database. EDM describes the structure of your business objects. It's as though you were given permission to restructure the database tables and views in your enterprise's database so that the tables and relationships look more like your business domain rather than the normalized schema that is designed by database administrators. Below compare a database model and a entity data model.