I have a WebApi2 project with EF6 CodeFirst. I'm also using AutoMapper to map between my models and dto's. I'm not using OData.
I'm trying to find a solution to handle updates of entities. As I'm not using OData I can't use Delta and I would not like to use JsonPatch.
In my scenario:
- Client sends the data (as dto) to the server
- Server loads the associated entity / entity graph from the DB using EF
- Server should patch the entity with values of the dto
- Server saves the patched entity and EF should take care of change tracking
My problem lies with 3.
Can I use GraphDiff for patching entities? (I will also be using GraphDiff was updating complex graphs). And if I can use GraphDiff, will EF change tracking kick in automatically?