Monday, September 6, 2010

LightSwitch Concurrency

 

I was curious how LightSwitch dealt with database concurrency, so I setup a little test to find out. I started with the sample application I have been working on in my previous posts. First I published the application then ran the setup and finally started two instances of the application. Next I added a new record, and then opened it for editing in both instances. In one instance I made a change to the Address field and saved the record. In the second instance I made a change to Start Date field and clicked save. When I did this LightSwitch detected the concurrency violation and displayed the following screen:

clip_image002

Here for each conflicting field you receive a drop down menu where you can select between the value on the server and the one from your instance.

No comments: