Man working with laptop
Working With Extension/Model (Part 4) – D365FO
November 4, 2019
AXGuru-D365-oData
Consuming D365 OData and OData actions – .Net
December 3, 2019

Introduction to Business Events – D365FO

Axguru_DYNAMICS365

Axguru_DYNAMICS365

Introduction to Business Events – D365FO

Introduction to Business Events


Introduction:
Business Events provide a mechanism that External systems can use for triggering any business action in response to the notifications sent by Microsoft Dynamics 365 using the Business events framework.
A business action that a user performs can be either a workflow action or a non-workflow action. Approval of a purchase requisition is an example of a workflow action, whereas confirmation of a purchase order is an example of a non-workflow action. Both type of these actions can generate business events which can be used in integration or notifications scenarios.
 
Pre Requisites:
Business events can be consumed using Microsoft Power Automate and Microsoft Azure Messaging Service. Therefore, to use business events one should have appropriate subscriptions.
For using Business events framework Platform Update 24 or later is required. It is not pre activated but it can be activated easily by performing the following steps.
Before moving forward, it is necessary to understand that the Business Events framework is not designed for exporting expensive payloads of data. Using it for data export can cause issues. For data export other data management frameworks should be used.
 
Steps for Enabling Business Events on Non Production Environments:
For Production Environments the following steps are not advised, for enabling Business Events in Production environment a support case with Microsoft should be logged.
 
·         Log on to your VM and open the Sql Server Management Studio. Execute the following query on the D365 database.
 
INSERT INTO SYSFLIGHTING (FLIGHTNAME, ENABLED, FLIGHTSERVICEID) VALUES (‘BusinessEventsMaster’, 1, 12719367)
 
 
·         After successful execution of the specified query check if the following line has been added in the Web config file.


 
·         Open the Command Prompt and run the “iisreset” command.


 
·         You are almost done, now open the Dynamics 365 client and navigate to the Business Events form (System Administration -> System Parameters -> Business Events – Preview). Toggle the Enable Business Events button to activate the business events.


 
Business Event Catalog: 
·         It is the main form which lists all the business events that are available in the instance you are using. The navigation of this form is (System Administration>Setup>Business Events). The Business Event Catalog form is updated at the time of database synchronization.


You can explicitly update the Business Event Catalog form as well, for this purpose select (Manage>Rebuild Business Events Catalog) in the Business Events Catalog form.
 
·         For each Business event, the Business Event Catalog shows a description. The Catalog also shows the list of data fields that will be sent out in the event.
 
·         The schema of the payload can also be downloaded in JSON format if required by the external system during development.
 
Supported Endpoints:
Business events can be consumed using different endpoints. It let you manage the destinations for sending business events to. The following types of endpoints are currently supported. Endpoints can be created for these messaging and event brokers out of the box.
  • Azure Service Bus Queue
  • Azure Service Bus Topic
  • Azure Event Grid
  • Azure Event Hub
  • HTTPS
  • Microsoft Power Automate
 
Activating business events
Business events in the business event catalog aren't active by default. From the catalog, you can activate any business events that you require. Select one or more business events, and then select Activate. At the time of activation, you need to mention a valid endpoint where the payload will be sent.
Business events can be activated either in all legal entities or in specific legal entities. If you leave the Legal entity field blank, the selected business events will be activated in all legal entities. If a business event is required only for specific legal entities, it must be configured separately for each legal entity.
When business events occur as business processes are run, the system will do outbound processing only for business events that have been activated.
 
This is it for today’s blog, In the next blog we will dive into the development of the Business Events Until then keep visiting our blog site for exciting and insightful information about Microsoft Dynamics.

For any further information