Continuing our previous post
Here we’d add a new Shared Access Policy in the Azure Service Bus.
We can copy the connection string
Paste it in Service Endpoint registration dialog box of Plugin Registration tool
Change the designation type to OneWay, use https for the namespace address.
Register a step for creation of lead
Now we go and create a lead record, which triggers our plugin and creates a system job for it.
The system job fails as we do not have any active listener at the end point.
Now let us create a simple windows application which will act as listener.
Basically, we need to implement IServiceEndPointPlugin Interface, create a Service Host, define a new transportclientendpointbehaviour with shared access signature token provider, use WS2007HttpRelayBinding in our service end point.
Now run the listener application, and create a lead record in CRM.
We can see the break point hit in our listener application’ Execute method. Execute method is invoked whenever a message is posted to the service bus by Microsoft Dynamics 365.
System Job also shows the status as succeeded as we had our listener registered to the endpoint and running.
The helpful post
Hope it helps.