Using the Visual Programming Language (VPL) as a Deployment Tool

image When building applications using CCR, DSS and VPL one doesn't need to know a priori the precise order of data and message flows between services. Many of the VPL examples provided with the MRDS show services already 'wired' up which can give the impression that one needs to know this information and design one's set of services to be orchestrated as such up front. What if you don't know this information up front but still want to use the VPL? Well, there's the pub/sub pattern supported by DSS out of the box which is very handy and well-understood. Or one can define a 'host' service that acts as a message forwarding system based on its own service directory (perhaps using the one built into DSS). Or one can use an external configuration file that defines the orchestration itself (like a BPML specification, say). Additionally, one could use UPnP device (service) discovery.

But orchestration is not the only thing, what about deployment? Well, the VPL also supports service deployment and this works across multiple physical nodes too!

Angel Lopez has extended his Web Crawler sample and without knowing the orchestration a priori uses VPL simply to create multiple instances of his several service 'agents'. The actual 'orchestration' is emergent as a result of collaboration between his agents and the 'agent host' - in fact he can have several agent hosts in the same Web Crawler application. The agent hosts forward messages to service agents based on their capabilities inferred from a logical 'URI' which gets physically bound when the agents themselves register with their (machine) local hosts. Should more than one agent service offer the same capability, such as web crawling or page downloading, the agent host will automatically load balance across them.

An interesting benefit of using the new VPL (in the April 2008 CTP of MRDS) is its ability to deploy services on multiple DSS nodes which themselves can be hosted on physically different machines. Angel does this with his Web Crawler application and together with the application-level load balancing facility his sample offers a neat and simple outline of potentially powerful solutions that you can build using this approach. I particularly liked the lack of a priori orchestration and the use of VPL as a multi-node deployment tool.

Check out Angel's application here.

Comments (0)

Skip to main content