Dynamics 365 Finance & Operations and CRM Together With CDS Dual-write
Dual write Overview
Dual Write is a good way to integrate Dynamics 365 F&O with CDS that is very similar to the Data Integrator, there is one difference: after the initial synchronization of data, the both side integration is synchronous or real time. Instead of saving the data to one database, all save is committed in both F&O and CDS at the same time.
Dual-write serve tightly coupled and bidirectional integration between Finance & Operations application and CDS (Common data service). If any CRUD event is occurs in Finance and operation application than it write to Dataverse, and if any CRUD event is occurs in Dataverse than it write to Finance and operation application. This automated data flow provides an integrated user experience across the apps.
Infrastructure
- Synchronous and bi-directional data flow between the F&O and CRM side.
- Push the initial synch data between the F&O and CRM
- Ability to configure the customer alerts and notification
- Set the relationship (lookups) and dependencies between the parent and child masters.
- Support the standard and customer mappings
Dual Write: Architecture
Dual write mappings always trigger when any events occurs on the table insert/update/delete.
Whenever any records is going to be inert or update from the CRM side then it triggers the plugin and push the data into the F&O.
Same way if any record going to be insert or update from the F&O then it triggers the event of table level and push the data into the CRM using the dual write mappings.
System requirements and prerequisites
- Make sure you have version 10.0.9 installed in the F&O environment (PU 33 or above).
- Install Dual Write Core solution from App Source in your CDS environment and enable the dual write entity map solution.
- Grant required accesses so that CDS and F&O can connect to each other.
- You can see the detailed documentation on here.
https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/data-entities/dual-write/requirements-and-prerequisites
Configuration
Link the Environment
- Log in to Dynamics 365 Finance and Operation environment and Open the Data management workspace and click on the Dual write tiles to open the dual write
Go to Workspaces > Data management, and select the Dual Write tile. - If this is the first time you are linking your Dynamics 365 Finance and Operations environment to the Common Data Service, you will see a message No environment is setup for dual write Click on the Link new environment to enter the Setup link to Common Data Service wizard, Click on the New link to environment to open the Setup link to Dataverse wizard.
- The Choose environment page lists all the CRM environments where the signed-in user is an environment admin. Select the CRM environment to link to, and then select Next.
- In the Setup link to Common Data Service wizard, select all legal entities from the list that you want to be synch, and then select Next.
- A health check is run to verify that your system meets the requirements for enabling dual-write. Health check screen verify the all the prerequisite are validate or not. If any error occurs, it will show the error mark into the same screen.
- Summery Details of the both the environment and legal entity details.
Health Check
Before you going to setup the new entity mappings between F&O and CRM, you can check the health check of the dual write,
Just verify the all the details like version and solution are verified in the health check details. It is showing the details of the Tenant and core solution which are installed in the CRM side and application version on both the side.
Mapping details
Add new table for the map
- Add new mappings by selecting the entity from the F&O and CRM side from the below dialog and define the version of your mappings.
- Select the required field for the integration from the F&O and CRM side and save the mappings.
Edit query (Set range to synch the data)
In the Edit query dialog you can set the filters based on your recruitments and based on that filters records are being synch from the both the side.
|
Finance and Operation query |
CRM(CDC) side query |
|
(SEGMENTCODE == “TEST”) |
SEGMENTCODE eq
‘TEST’ |
|
((SEGMENTRECORD > 100)) |
SEGMENTRECORD gt 100 |
Synch direction
- Customize the synch direction (Bidirectional or Unidirectional) based on your recruitments.
- Below is the description of the Map type/Synchronization direction description that you can set over the filed between the F&O and CRM.
Transform on the Map type
On the field mappings you can do any transformation on the value synch like set the default value or convert any value.Transform on the Map type
|
Transformation Type |
Details |
|
Default |
You can set the any default value for the particular field. It will take this default value while synch the data from the particular direction |
|
Truncate |
You can truncate the any value with the specific
length for the particular field. It will trunk the define length while synch
the data. |
|
ValueMap |
You can convert any field value with the specific combination from the list. |
Synchronize the Data
Initial synch
If you want to copy all the pre-existing data between both the Environment F&O and CRM, You just have to start the Initial synch by clicking on the Run button and Click on the Initial synch tick mark and selected the direction from where you have to push the data.
Live synch
If you want to start the live synch between both the Environment F&O and CRM, You just have to start the live synch by clicking on the Run button and unchecked the initial synch tick mark and click ok.
Now you can create the new record and it will synch automatically with the destination environment.
Move Dual write mappings across environments
This section explains how to export your customized table maps as a solution, use it as a backup, and move the artifacts across environments and/or publish them to App Source.
Export the solution from the Power apps
Prepare the new solution
After create new solution click on add existing and select the Dual write table map from the list and add your all custom mappings from the list to current solution.
Export the solution
Now open your newly created solution and export your all mappings from the particular environment from the Power app by clicking on the export button.
If you made any changes in current solution mapping than publish before the export the solution and Run the Check for issue to rule out the performance and stability issue.
Mention the new version of solution and there are two option for the export one is from Manage solution which is used when you are moving you mappings from the Dev environment to Production Environment and another one is Unmanaged which is used to move your solution from the Dev to another Dev Environment or Test Environment.
Once you click on the export it will export the zip file of current selected solution.
Import the solution into the new environment
First login to make.powerapps.com and select your production or Dev environment and click on the import button on the top of the page.
Import the solution into the power apps
Browse the exported zip file from the existing export environment and import the new solution
Apply the new solution into the Dynamics 365F&O
Open the Dynamics 365 Finance and Operation environment and Click on the Apply solution button.
Select the particular solution from the list and click on apply to import the all the mappings from the solution.
Error management and Alert notification
Synchronization Error
If you are trying to copy the pre-existing data between the F&O and CRM, the Initial synch details tab provide you the all the details regarding the error and total count of record which are inserted.
Alert Notification
You can setup the alert like if any error occurred during the sync of the data and error occurred because of any network or any other issue then it will notify you by the email with the specific error details.
The following illustration shows an example where dual-write will be paused if any errors occurs.































Comments
Post a Comment