Step 5: Create and Deploy the EDI Receive Pipeline
Important
Microsoft Azure BizTalk Services (MABS) is being retired, and replaced with Azure Logic Apps. If you currently use MABS, then Move from BizTalk Services to Logic Appsprovides some guidance on moving your integration solutions to Logic Apps.
If you're brand new to Logic Apps, then we suggest getting started here:
-
Create your first logic app, or quickly get started using a pre-built template
-
View all the available connectors you can use in your logic apps
In this topic, you configure the EDI Receive bridge that receives an X12 850 PO message from an FTP server, processes it, transforms it to an ORDERS05 IDOC, and then routes it to the XML One-Way Bridge that you deployed in the previous step.
To configure an EDI Receive pipeline
Log into the BizTalk Services Portal. You can get the URL for the BizTalk Services Portal from your BizTalk Services subscription. For more information about logging into the portal, see https://go.microsoft.com/fwlink/p/?LinkId=317714.
Create a partner for Fabrikam and Contoso. On the left pane, select Partners, and then from the Partners page, select Add Partner.
Create an agreement between the two partners. On the Agreements page, select the EDI tab if you are not already on that tab. Then click Add.
Set the following values for the General Settings tab.
TABLE REMOVED
Select Continue.
Selecting Continue adds two new tabs: one for receive settings and the other for send settings. Each tab is for a one-way agreement between the two partners, one for receiving messages and the other for sending messages. The properties in the Receive Settings tab define how the EDI receive bridge is configured. This bridge receives incoming EDI messages that are sent to Fabrikam. Similarly, the properties in the Send Settings tab define how the EDI send bridge is configured. This bridge sends EDI messages from Fabrikam to its trading partners like Contoso.
To specify the receive settings
From the agreements page, select the Receive Settings tab.
Enter the following values for the Transport section:
For Transport Type, select FTP. In the scenario used in this tutorial, Contoso sends the X12 850 message using an FTP location.
Provide the name of the FTP Server from where the messages are picked.
Enter the username and password to connect to the FTP Server.
Enter the relative path on the server from where to pick the X12 850 message.
Enter the following values for the Protocol section:
Enter whether you want to receive technical (TA1) and functional acknowledgements (997).
Under Schemas, select the plus sign and specify the following values:
For this
Specify this
For Version
Specify 00401.
For Transaction Type (ST1)
Specify 850 – Purchase Order.
For Sender Application (GS02)
Specify CONTOSO.
For Schema
From the drop-down list, select the schema (X12_00401_850.xsd). This schema was uploaded to your BizTalk Services when you deployed the BizTalk Service project in the last step.
In the Transform section, select the plus sign to add a transform to the agreement. From the drop-down list, select the X12_00401_850.xsd schema and the transform you created earlier (AzureTransformations.trfm). The schema as well as the transform is deployed to the BizTalk Services subscription when you deployed the BizTalk Service project in the previous step:
On the Route page, under Route Settings, select Add to add a route destination.
Set the Rule Name to SendToBridge.
Under Route rule, select Use advanced definitions, and enter the following expression in the text box:
1=1
This expression always resolves to true, which means that all the messages are routed to the bridge.
Note
Even if you do not select the Use advanced definitions option and do not provide any route rule, by default this option is selected and its value is set to 1=1. This means that the default behavior is to route all the messages to the route destination.
Under Route action, select the plus sign to add a new row and set the following values:
Set Target Type to Http Header
Set Header Name to Content-Type
Set Value Type to Constant
Set Constant Value to application/xml
Note
This ensures that all the messages that are routed to the bridge include a content-type header with its value set to application/xml. Without this header, the bridge receiving the message treats it as a flat-file message and might result in validation errors.
Under Route destination, set Transport type to Azure BizTalk Bridge and in the text box enter the entity name of the bridge on the message flow surface. For this tutorial, you specified the bridge name as B2BConnector. Using this name the bridge deployment endpoint is built, which is https://<mybiztalkservicename>.biztalk.windows.net/default/B2BConnector. With this configuration, all the messages processed by the agreement are routed to the XML One-Way Bridge bridge you deployed earlier.
Select Save.
On the Route page, under Message Suspension Settings, enter the Transport Type as Azure Service Bus, and then enter the following values:
Set the route destination type to BasicHttpRelay.
Enter the Service Bus namespace, issuer name, and issuer key.
Enter the endpoint URL where a relay receiver service is already running. For this tutorial, specify this as Suspend. So, the complete URL where a failed message is sent is https://<servicebus_namespace>.servicebus.windows.net/Suspend.
To specify the send settings
From the agreements page, select the Send Settings tab.
Note
Even though this tutorial does not cover the send side of the agreement, you must specify the minimum default values to successfully deploy the agreement.
Retain the default values Inbound URL, Transform, and Batching tabs.
In the Protocol tab, under Schemas, enter the following values:
Property
Description
For Version
Set this to 00401
For Transaction Type (ST01)
Set this to 850 – Purchase Order
For Schema
Set this to X12_00401_850.
In the Transport section, under Transport Settings, enter the following values:
Set the Transport Type to FTP/S.
Enter the required values for the FTP transport.
In the Transport section, under Message Suspension Settings, enter the following values:
Set the Transport Type to Azure Service Bus.
Set the route destination type to BasicHttpRelay.
Specify the Service Bus namespace, issuer name, and issuer key.
Specify the endpoint URL where a relay receiver service is already running. For this tutorial, specify this as Suspend. So, the complete URL where a failed message is sent is https://<servicebus_namespace>.servicebus.windows.net/Send_Failure.
Select Deploy Agreement to deploy the agreement.
Once the agreement is deployed, to test the solution, you can go ahead and drop a test PO 850 message in the folder on the FTP server that you specified as part of the agreement. More details on how to test the solution are provided in the next topic, Step 6: Test the Solution.
See Also
Tutorial: Using Azure BizTalk Services to Integrate with an On-Premises SAP Server