01 January 2012

MSCRM2011 integration with Windows Azure (AppFabric) - Part 1

As Microsoft steps into the Cloud service with CRM 2011, Windows Azure platform AppFabric Service Bus provides an end-to-end solution option for us to integrate with CRM 2011 Online. It enable the data that has been processed as part of the current MSCRM operation to posted to the bus. Futher more, it provides a secure channel for communicating CRM run time data to external cloud applications. This is useful in keeping CRM systems and others data source synchronized.

Diagram below shows the how the AppFabric serve as a middle man:
Service bus messages are received at an endpoint using: (Detail explanation can be found on the SDK)
  • Queued
  • One-way
  • Two-way
  • REST
After a long summary on what AppFabric can do, lets see how to configure it. In this part 1 section, I will used CRM 2011 Online + Azure AppFabric as an example with step by step screen explanation:

Note: Microsoft Windows Azure upgraded ACS to version 2 on April 2011, for compatible checking, read the detail in this article.

First of all, we need to have CRM2011 account, Windows Azure account and CMR2011 Plugin registration tool... (You can also signup for free trial 30 days for CRM2011 & 3 months Windows Azure platform free trial, refer my previous post)

Step 1: Open the CRM 2011 Online in browser,navigate to the Developer resources screen from setting tab. Download the Certificate file and remember your Issuer Name. [We need to use this value in later stage!]

Step 2: Login to your Windows Azure Platform portal. change to Service bus, access control and caching page. Click the new ribbon button on top to create a new subscription service bus. [CRM will connect to this bus later]

Step 3: System will prompt you for namespace value, region and service you want to create. [Namespace must be unique, you can use the check button to verify. In my case, I used "EastOceanDevelopmentBox"]

Step 4: Wait few minutes for the Azure platform to create your service, you will see the status turn to Active. On the right hand site of the portal, from the properties section, notice that the ACS version is version 2, and there is a default key you will need to refer during the plugin registration stage for service endpoint.
Click on the view button you will see the similar screen as below: [Default key required on plugin registration stage!]

Step 5: Open a precompiled CRM2011 Plugin Registration Tool. Select the "Register New Service Endpoint" option.

Step 6: In the service end point details screen.
Fill name for this service.[It will display in CRM system job screen]
Fill in the solution namespace with the one we created in step 3. [EastOceanDevelopmentBox]

Fill in the Path. [Your service bus URI, example: https://eastoceandevelopmentbox.servicebus.windows.net/RemoteService]
Choose the contract you want and click the save and configure ACS button.

Step 7: In the ACS configuration screen, Paste the default key in step 4 as the Management Key
Browse the certificate we downloaded earlier. Paste the issuer name, all can get from CRM developer resource. Click Configure ACS.
You will see something similar as screen below.

 Step 8: On the service endpoint detail page, click save and verify. Then close.
If everything configure nicely without error,  a new system event record should appear in the CRM system job view with the name I key in earlier "CRM 2011 Online" status succeeded. Refer screen below.
Hooray! Now the CRM is connected to Azure and we can run our listener program to capture the context values.

I will try to post the part 2 ASAP, for part 2, I will demo how to register step with service endpoint and the different type of contract interaction that can use.

Cheers...

0 comments :

Post a Comment