Introduction

This blog explains how to deploy the Advantco Dynamics 365 adapter and a detailed step by step to create a REST endpoint to create Account in Dynamics 365.

 

1 Download and Install Oracle SOA 12c

Please refer the link: https://docs.oracle.com/middleware/1221/core/SOAQS/GUID-3C1D5593-9EF2-47C7-930C-A966DD1EFDD9.htm#SOAQS470

 

2 Configure JDeveloper's default domain

 

3 Configure Advantco MS Dynamics 365 Adapter

3.1 Registering the Advantco MS Dynamics 365 Adapter with JDeveloper (Design Time)

        Copy the AdvantcoDynamicsCRMAdapter (JAR) to this location:

        %ORACLE_HOME%\jdeveloper\dropins

 

3.2 Registering the Adapter with SOA Suite (Run Time)

  1. Copy the AdvantcoDynamicsCRMAdapter (JAR) to this location: %ORACLE_HOME%\soa\soa\modules\oracle.cloud.adapter_12.1.3

 

  1. 2) Add the adapter JAR file to the CLASSPATH by editing the setDomainEnv script file. This file is in the bin subdirectory of the domain directory.

For example:

set POST_CLASSPATH=D:\Oracle\12.2.1.3\soa\soa\modules\oracle.cloud.adapter_12.1.3\AdvantcoDynamicsCRMAdapter.jar;%POST_CLASSPATH%

  1. 3) Restart the Weblogic SOA Server

           

 

4 Create Integration Flow

4.1 Create SOA Application

 

4.2 Create SOA Project

 

4.3 Configure Outbound Advantco MS Dynamics 365 Adapter

 

REST Service URL: https://yourcompany.api.crm.dynamics.com/api/data/v8.2/

 

4.4 Configure Inbound REST Adapter

Add resource

Add method

Configure schema for request

Click Next and choose “XML Sample”

<Account>

    <Name>SOA Account</Name>

</Account>

Configure schema for response

Click Next and choose “XML Sample”.

<Response>

    <OperationName>Create</OperationName>

    <Id>AccountId</Id>

</Response>

4.5 Configure BPEL Process

Insert BPEL Process

Press OK button

Then Click the icon as below:

The interface of the BPEL process does not fit to our REST service and needs to be removed. Click the symbol of the inbound interface so that the surrounding circles is represented by a dotted line. Press the 'DELETE' key on your keyboard and answer both questions with 'YES'.

Now the RestService can be wired to the BPEL process.

Double click to Open the BPEL Process.

The input and output variables for the old interface are still there. They need to be removed by clicking on the variables button (x), mark both and click on delete.

Switch to source view. The old WSDL is still imported, so the line reading <import ui:processWSDL... needs to be deleted.

Duoble click on:

The receiveInput can now be wired to the RestService, Change the Port Type to the new RestService_ptt.

 

A new input variable is needed. Click on 'Auto-Create Variable’ and in the 'Create Variable' dialog just click 'OK'.

Wire the replyOutput also to the RestService and repeat the steps above.

Now, Wire the BPEL process to createAccount.

Put an Invoke activity right behind receiveInput and wire it to createAccount.

 

Create a new input and output variable via the green plus and close the dialog.

4.6 Mapping

Put a XSLT Transform right behind the receiveInput.

Add source schema

Add target schema

Do the mapping:

Set the RequestName value is “Create” and the LogicalName value is “account”.

Put a XSLT Transform right behind the receiveInput.

Add source and Target schema

Do the Mapping

 

4.7 Deploy and Testing

Start the SOA Suite instance (if the SOA instance is not started)

Deploy SOA project to a SOA Suite instance.

Open the Oracle Enterprise Manager and go to the soa-infra. http://host_name:port/em

Select the project, click the test button and choose the RestService.

Enter payload request and test the service.

<Account>

    <Name>Oracle_SOA_Account</Name>

</Account>

The response result:

Check result on the MS Dynamics365

pic1.png

Monitor message on the Oracle SOA Suite

Summary

The Advantco Dynamics 365 enables integration between any Oracle applications and MS Dynamics 365. The adapter is also available for Oracle Integration Cloud.

advantco.jpg