Friday 14 October 2016

AIF Part 1: AIF is an acronym for Application integration framework. This framework is utilized for integrating third part applications with Microsoft Dynamics AX. This framework is widely used in AX implementations and makes the developer's life easy for integrations.

Below are the basics we need to understand before stating  the actual work on integrations.

  • Any third party application which supports XML can be integrated with AX for data exchange.
  • AIF has the ability to perform both inbound and outbound data exchange.
  • AIF supports both synchronous and asynchronous data exchanges.
  • WCF (Windows communication foundation) is the base for AIF framework.
Terminology.

We can easily find these terms in more details on MSDN, here I am trying to explain the essence of it in simple manner

Service: A service is open standard (XML, SOAP, HTTP etc.) based Web application that interact with other web applications for the purpose of exchanging data.

A service contains methods which can be exposed to web world to perform the business logics and data exchanges within and outside AX.

Service Types: A service in AX can be defined in two types
1. Synchronous:  Synchronous service is a real time response request architecture, where the request is served at the same time user demands it.
2. Asynchronous: Asynchronous service is basically a batch process which serves the multiple requests on scheduled date and time as configured.

Ports: AX has two types of ports.
1. Basic: A basic port is created when we deploy the service group. A basic port is created when the service is hosted by AOS in AX.
2. Enhanced: Enhanced port is created for configuring the data policies and security constraints. Also we the AX services are hosted on internet than we can only use enhanced ports.

Adapters: Adapters decide the mode of communication for the service. Most commonly used adapters in AX are as follows.
1. HTTP: HTTP is used for hosting the service on internet.
2. NetTcp: NetTcp is used for hosting the service on AOS.
3.FileSystem: This port is used for asynchronous services, where the data exchanges happen through files.

Data exchange type: AX has capability to perform both inbound and outbound operations.

Inbound: The services which are created for taking the input from external systems and perform operations in AX are called inbound ports. Inbound port support both synchronous and asynchronous services.

Outbound: The services which are created to export the data from AX based on any business processes or any particular time and period. Outbound port only support asynchronous service type.

AIF Part 2:
If we are familiar with above terminology, we can go ahead to understand the actual artefacts of the AIF.


AIF provides the multiple types of services, each of them have their own significance in different requirements on any implementation.

1. Document service: The first question that could come in mind of any new comer is " what is document service: or "why we call it document service".
Answer is: An ERP is considered to be the repository of documents where we have multiple transactions performed and recorded for a particular document, So what we can say is "Sales Order is a document of an order placed by customer". Similarly we have multiple documents in terms of customer, purchase order, quotation etc... In order to perform any action from third party applications on these documents, we have document services available in AX.
We can use standard document services and can create also as per our business needs.

2. Custom service: A custom service is the set of functions available on service methods to perform the business logic. For ex: If I have an external application which is responsible for the confirmation of the sales order and the same trigger I want to confirm the SO in AX as well than a custom service can be created which expose the business logic for confirmation of sales order.

3. Query service: These are the standard services which serves the purpose of fetching the data from AX on any particular query. For ex: If I have a third party application which needs to show the set data from AX, than we can use query services.

In my next post I will explain all these three service types one by one with more detailed steps, code and customization aspects.

































 

No comments:

Post a Comment