Refactoring My Repository Methods to be Asynchronous

Now I’ve written a DocumentDB based repository for Equipment data in DungeonMart, but I didn’t try to make it perfect, I just tried to make it work. Here it is, if you’re catching up: Part 1 and Part 2.

My next step in getting it closer to perfect is to make all the methods aynchronous. Face it, we’re going out to the cloud to get or write data and we shouldn’t make the whole service wait while that happens. DocumentDB gives you Async methods at least for writing, and we can figure out how to make the read methods async. If we were in Entity Framework, we would already have async methods for both reading and writing.
Continue reading