Skip to main content

Registering Service Endpoint for Azure Service Bus Topic in Microsoft Dynamics 365 CE

I will be using Plugin Registration tool to register Service Endpoint for Azure Service Bus Topic in my trial Microsoft Dynamics 365 CE Instance.

Here are the steps to you need to follow:

Step 1. Login to your Microsoft Dynamics 365 CE instance using plugin registration tool.


Step 2. Once logged in, Press “Ctrl + E”, or from file menu, go to Register -> Register New Service endpoint.


Step 3. Enter your Azure Service Bus Connection String in the shown popup, and click OK.


Step 4. You will be presented Service Endpoint Registration popup, where you need to enter following details:

Name: ASB Topic Endpoint (a friendly name to your service endpoint)
Designation Type: Topic
Topic Name: test_internal (enter your ASB Topic Name here)
Message Format: JSON (can be .NET Binary, and XML as well)
User Information Sent: None (can choose to pass on User ID as well)

After entering these details, click on Save.


Step 5. The Service Endpoint will be registered and will appear on the bottom of the list.


Step 6. Now we will register step on our Service Endpoint. For this, right click on the Service Endpoint and select Register New Step Option.


Step 7. You will be presented with the Register New Step popup. This is just like the way we register step on top of our plugin assembly. You will have to select the following fields:

  • message,
  • primary entity,
  • secondary entity,
  • field attributes (for Update),
  • Step Name,
  • Stage of Execution,
  • Execution Mode (only Asynchronous mode supported on step that is being registered on Service Endpoint) etc.

Once you have entered these values, click on Register New Step button.


Step 8. Your step will be registered and shown as a child node under your registered Service Endpoint. Click on your service endpoint and go to Properties section. Here you can get the serviceendpointid of your service endpoint. This will be required when you will be passing data to ASB from inside your plugin or workflow.


Step 9. NOTE – If you try to use Synchronous mode while registering step onto your Service Endpoint, it will throw an error when you click on the Register New Step button. This is because it only allows Asynchronous mode on the Service Endpoint. The below two screenshots demonstrate this scenario and show the error message that is thrown when we try to do this.



Hope this is helpful, Happy Coding :)

Comments

  1. Needed to compose you a very little word to thank you yet again regarding the nice suggestions you’ve contributed here.
    Expence Reports

    ReplyDelete

  2. Excellent idea you have shared. Thank you for the useful info. Share more updates.
    Azure Online Training
    microsoft azure online training

    ReplyDelete

Post a Comment

Popular posts from this blog

Handling Concurrency in Azure Functions (HTTP Triggered)

Concurrency & Isolation Concurrency is one of the most common requirements when we don't want the resource to be accessed by multiple requests at the same time. Lets say we have a Database that holds products stock information, then it is very important that any read/write operation that happens on the Database must hold the property of Isolation . The isolation property ensures that the concurrent execution of transactions results in a system state that would be obtained if transactions were executed sequentially, i.e., one after the other. Providing isolation is the main goal of concurrency control. Depending on the concurrency control method (i.e., if it uses strict – as opposed to relaxed – serializability), the effects of an incomplete transaction might not even be visible to another transaction. Options Available in Azure Functions Recently while working on Azure Functions, I discovered a really simple way of handling Concurrency via code. There are ways to con

Azure Functions - Retrieve data from Dynamics 365 CRM/CE Online using CRM OData Web API

Introduction: This blog describes how you can retrieve data from Dynamics 365 CRM/CE Online in an Azure Function, using CRM OData Web API. The CRM Web API has a couple of advantages over the traditional SOAP based approach to interact with CRM. These are rest based services, its easy to use and transport over http protocol , and there is no need to use additional web resources (XrmServiceToolkit ) of SDK (SDK.REST). Here is a detailed documentation on CRM OData Wbeb API. I will be using an Azure Function Application in Visual Studio 2017 to retrieve records from Dynamics 365 CRM/CE, by making use of OData API Endpoint provided by CRM. Prerequisites: Dynamics 365 CRM Online Trial https://trials.dynamics.com/ https://signup.microsoft.com/Signup?OfferId=bd569279-37f5-4f5c-99d0-425873bb9a4b&dl=DYN365_ENTERPRISE_PLAN1&Culture=en-us&Country=us&ali=1 Azure Subscription related to CRM Online instance https://portal.azure.com/ Visual Studio 2017 with Cl

Retrieve 5000+ Records in Dynamics 365 CE using CRM OData, Fetch XML and C#

If you want to retrieve 5000+ records in Dynamics 365 CE, you need to make use of Paging concept of CRM. By default 5000 records are retrieved in a single OData call in CRM. To get more, you need to make subsequent calls to OData Endpoint by passing a paging cookie in the request. I will be using a simple C# Console Application to retrieve 5000+ records from Dynamics 365 CE, by making use of OData API Endpoint provided by CRM and passing Fetch XML in OData Call . Concept: CRM OData Endpoints allows us to use Fetch XML to retrieve data from Microsoft Dynamics 365 CE.  If your resultset has more than 5000 records, you will be returned with first 5000 records ONLY in one OData call. To know if the resultset has more than 5000 records, we make use of the response from OData call. The response is added with a cookie value contained in a key - "@Microsoft.Dynamics.CRM.fetchxmlpagingcookie" If you wish to fetch the next set of resultset data, you will have to pass this c