We had in Part 9 and Part 10 looked at handling Outgoing IDoc Bundles. We had looked at the limitation of Outgoing Packaged or Bundled IDocs from ERP and some workarounds for them. But, what about Incoming EDI Bundles? Does Trading Partner Management Support incoming bundled EDI Message? How does that work? What do we need to do to handled Incoming Bundled EDI Messages?
Example of our Bundled EDIFACT Message
Below is a example of a EDIFACT Interchange containing multiple EDI Messages. In simple words, a EDIFACT message containing multiple UNH Segments.
Before we get started on figuring out how bundled EDI Messages are handled in Integration Suite using Trading Partner Management, ensure you have done the required steps as described in Part 2 of our series. The scenario in Part 2 is what we will now process but with a Bundled EDI Message.
Good News – No Additional Adjustments Needed
If you have implemented Part 2 and have a Bundled EDI Message as your Incoming message, here is the good news. You do not have to make any adjustments at all. SAP in its standard Flows for Trading Partner Management Step 2 – Interchange Processing Flow V2, uses a EDI Splitter and that implicitly splits your EDI Message into Multiple EDI Messages and processed them over.
Test your Bundled EDI Message
Lets trigger the EDI Message from Part 2 as a bundled EDI Message with 2 UNH Segments. Ensure you have Trace enabled for all your Flows ( especially Step 2 – Interchange Processing Flow V2 ).
You will notice that the Step 2 – Interchange Processing Flow V2 splits your EDI message using EDI Splitter in the Step called “Validate and Split” and then your mapping exits and receiver flows etc are called twice, once for each EDI Message.
What About B2B Monitoring?
As your Bundled EDI Message is only Split in your Step 2 – Interchange Processing Flow V2, your B2B Monitoring will only have 1 Message. But, you will see multiple repetitions of the Sender Interchange Mapped, Receiver Interchange Assembled and Receiver Interchange Sent events in the B2B Monitoring. You will also see that you can see multiple Target Payloads for Receiver Interchange Assembled
What if you get different Message Types in your Bundled EDI Message
The good news is SAPs standard flow : Step 2 – Interchange Processing Flow V2, and the groovy script callPDwithHeaderParameters.groovy validates each EDI message and hence no partial EDI Messages are processed. If and only if the Partner Directory Lookup is successful for all EDI Messages, they are processed over. Again no customizations needed, everything works out of the box!
What If Target Wants a Bundled Message?
What if your Target ERP system wants a Bundled IDoc? Unfortunately this is not supported out of the box. Ideally, the SAP standard flow could have been extended to have a Splitter and Gather pattern but thats not yet supported. In a realistic EDI Implementation, sending Bundled IDocs to ERP is not always a hard and fast rule and hence in most cases you can live with what SAP has provided out of the box. But if you really need to bundle this, you would need to handle this by using a Aggregator Pattern as I have described in this Post: Trading Partner Management – Part 10 – Outgoing IDoc Bundling With EDI Bundling
Handling Incoming EDI Bundled is very straight forward in Cloud Integration using TPM. SAPs has addressed this solution out of the box and no special configuration and development is required for such a requirement.
If you have a Bundled Incoming EDI Message, expect the Partner Directory Lookup to handle each message and process the EDI Messages individually. In B2B Monitoring expect to be able to see each message individually.
Additional Blogs from this Series
- Trading Partner Management – Part 1 – IDoc to EDI Flow(s)
- Trading Partner Management – Part 2 – EDI to IDoc Flows(s)
- Trading Partner Management – Part 3 – EDI over AS2 to IDoc Flows(s)
- Trading Partner Management – Part 4 – IDoc to EDI over AS2 Flow(s)
- Trading Partner Management – Part 5 – Custom IDoc Flow
- Trading Partner Management – Part 6 – Custom Search Attributes
- Trading Partner Management – Part 8 – EDI Functional Acknowledgements for Outbound EDI Messages
- Trading Partner Management – Part 9 – Outgoing IDoc Bundling
- Trading Partner Management – Part 10 – Outgoing IDoc Bundling With EDI Bundling
- Trading Partner Management – Part 11 – Handling Parameters
- B2B on SAP Integration Suite – Part 12 – Migrating SAP PI / PO B2B Mappings without TPM
- Trading Partner Management – Part 13 – Migrating SAP PI / PO B2B Mappings with TPM
- Trading Partner Management – Part 15 – Handling Message Retries
- Trading Partner Management – Part 16 – B2B Failed Message Alerting
- Trading Partner Management – Part 17 – TPM Naming Convention Guideline