Bernie Cook's Blog

Azure, C#, .NET, Architecture & Related Tech News


Leave a comment

Distributed Design: Applying the Command Pattern to Azure’s Web/Worker Roles

WorkerRoleOne place I regularly come across the use of the Command pattern is when working on Azure projects that employ worker roles to execute long running tasks initiated by a scheduled process or user action. The Command pattern lends itself to the distributed nature of these solutions with very little plumbing required when working in Azure.

The following post provides a sample application; CommandQueue which contains 3 examples of a web and worker role utilising the Command pattern. The web role is designed to provide a rapid responses to the user, offloading any lengthy operations to the worker role. The source code for the CommandQueue solution is available on GitHub so feel free to clone, compile and execute it while working through this post.

Continue reading

Advertisements