Export (0) Print
Expand All
3 out of 5 rated this helpful - Rate this topic

Run the Sample SOA Application

Updated: April 10, 2013

After completing the steps in Steps to Configure and Publish the Sample Applications, you can run the sample SOA application that is included in the deployment. Running this application demonstrates how to submit service requests to the compute nodes from a SOA client that is installed on the head node.

For a video demonstration of deploying and running the sample SOA application, see Windows Azure HPC Scheduler code sample: Deploy and run the SOA demo on Microsoft Showcase.

In this section:

About HelloWorldAzure

HelloWorldAzure.dll is a sample SOA service that accepts an input string and then returns a new string that says “hello”. HelloWorldAzureClient.exe is the SOA client for this service. This type of SOA client uses the Microsoft.Hpc.Scheduler and Microsoft.Hpc.Scheduler.Session APIs to send and receive messages from a service that is hosted on one or more compute nodes. These APIs allow the client to leverage the Windows Azure HPC Scheduler infrastructure, which provides built-in functionality such as the identification of available service hosts, distribution of service requests, load-balancing, and error handling. For more information about enabling SOA support in a Windows Azure HPC Scheduler deployment, see the Implementation notes later in this topic.

Step 1. Deploy the SOA service to the compute nodes

The sample SOA service and client were both automatically deployed to the head node in Windows Azure. The servicehost.exe program expects to find the service DLLs on the compute nodes in a location determined by the CCP_PACKAGE_ROOT environment variable. You can use the hpcpack and hpcsync command-line tools to upload the service DLLs to your Windows Azure storage account and then deploy the service to each compute node. Hpcsync automatically deploys the DLLs to the expected location. 

To perform the following steps, you must have the storage account name and primary access key.

To deploy the SOA service to the compute nodes

  1. Open a remote desktop connection to the head node in the deployment. For more information about making a remote desktop connection to a node in your deployment, see Verify the deployment in this guide.

  2. Navigate to the E:\approot folder.

  3. Create a new folder named HelloWorld.

  4. Move the following files to the new folder (from E:\approot to E:\approot\HelloWorld):

    • HelloWorld.config

    • HelloWorldAzure.dll

    • HelloWorldAzure.pdb

  5. Open a command prompt.

  6. Type the following command to package the SOA service:

    hpcpack create e:\approot\helloworld.zip e:\approot\helloworld
  7. Type the following command to upload the package to your Azure storage account, where <yourStorage> is the name of your storage account, and <yourKey> is the primary access key to your storage account:

    hpcpack upload e:\approot\helloworld.zip /account:<yourStorage> /key:<yourKey>
  8. Type the following command to deploy the package to all compute nodes:

    clusrun hpcsync

Step 2. Run the SOA client on the head node

To submit service requests to HelloWorldAzure, you can run the SOA client, HelloWorldAzureClient, that is installed on the head node.

To run the SOA client

  1. If you have not already done so, make a Remote Desktop connection to the head node in the deployment.

  2. Open a command prompt.

  3. Type the following command:

    e:\approot\helloworldAzureClient.exe yourName
  4. When prompted, provide your user name and password.

    The output will contain text similar to the following:

    Sending requests...
    Committing requests...
    Waiting for responses...
    Hello yourName
    Hello yourName
    Hello yourName
    Hello yourName
    Hello yourName
    Hello yourName
    Hello yourName
    Hello yourName
    Hello yourName
    Hello yourName
    Complete. Press ENTER to exit...
  5. Press Enter to exit.

Step 3. View the compute nodes that were allocated to your service requests

To view the compute nodes that were allocated to process your service requests, you can use HPC Job Manager.

To view resource allocation

  • On the head node, start HPC Job Manager.

  • In the Job Management pane, click All Jobs.

  • In the job list, double-click the job named “HelloWorld – WCF service”.

  • In the View Job dialog box, click Allocated Nodes. The Allocated Nodes tab lists the resources that were used to process the service requests.

Implementation notes

  • In the sample Windows Azure service, the head node was enabled for SOA workloads. A deployment that supports SOA workloads provides broker and session management functionality to help distribute incoming service requests to the available service hosts and then return the messages to the client. This functionality can be enabled in the ServiceConfiguration.cscfg file for the deployment. The necessary elements can be added to the configuration file by calling the EnableSOA method (in the Microsoft.Hpc.Azure.ClusterConfig namespace).

See Also

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
© 2014 Microsoft. All rights reserved.