SAP in its latest update on Trading Partner Management in Dec 2023 has introduced configurable retries for the your Standard Trading Partner Management IFlows. With the SAP Trading Partner Management Package Cloud Integration – Trading Partner Management V2 version 2.2.0, SAP now supports Customizable message retries.
Ensure you have upgraded your SAP Cloud Integration TPM Package to version 2.2.0 or above. If you are just starting your TPM Journey ( Dec 2023 and later), then the standard Package you import from the Discovery Center of your SAP Integration Suite will be 2.2.0 or above.
Configuring Max Retries
If you have paid attention to what happens on the standard IFlows from SAP for Trading Partner Management you would have noticed that there are 2 Iflows that use JMS Queues. Step 2 – Interchange Processing Flow V2 and Step 3 – Receiver Communication Flow V2. As both of these do most of the heavy lifting of your EDI Transformation in Cloud Integration, errors in these flows are inevitable and hence the design choice by SAP to use JMS in their standard flows.
Unlike most Integration Flows from SAP where you configure Max Retries of your JMS Queue in a Externalized Property of your Integration Flow, in the case of Trading Partner Management on Cloud Integration you handle this within Configuration Manager on Trading Partner Management.
Configure the Max Retries in Configuration Management
Navigate to Design -> B2B Scenarios -> Configuration Manager and in this section you will find the Maximum Retry Count section. By default the Max Retry are set to 3 by SAP and you can increase of decrease them to a Maximum of 25. Change your settings as you deem fit in this section.
|Interchange Processing Flow
|Step 2 – Interchange Processing Flow V2
|Receiver Communication Flow
|Step 3 – Receiver Communication Flow V2
Retry Data Stored in Partner Directory
Once this data is changed / stored in your Partner Directory, you can see them in the Partner Directory Data in TPM. Go to Partner Directory Data in TPM and SAP_TPM_Global_Parameters
SAP_TPM_IFLOW_STEP2_RETRY_COUNT and SAP_TPM_IFLOW_STEP3_RETRY_COUNT are the parameters with which these values are stored for the Interchange Processing Flow and Receiver Communication Flow respectively.
Test / Ensure your IFlow Fails
While beyond this it is self explanatory that the retries are handled out of the box, for the sake of completeness, test your flows and ensure that your messages fails either in Step 2 or Step 3. Ensure you have the trace on in these IFlows. You will notice that the message now goes into Retries and then is Escalated after max retries are handled.
Why this post on Retries you might ask?
Prior to Dec 2023, messages in TPM went into Infinite Retries. There was no Retry handling done by SAP in their standard content. While this has been fixed now, as we can see in this post, it also opens up the reasoning as to why alternate TPM Solutions exists on Integration Suite for B2B Messages. SAPs roadmap for TPM is impressive but there can be times ( like any other product ) when you can hold your head in anguish and wonder how was this missed in a standard Product and this was one such case, that now has been addressed!
What if you want to re-process this Escalated Message?
Well, at this moment ( Dec 2023) you cannot do that out of the box. You need to resend the message from Source or you need to build a custom retry solution. In our case, we have copied the Standard SAP Flow ( to allow for Upgrades to standard Flow) and then when the message goes into Max Retries,
- Pushed the message to a JMS Dead Letter Queue or
- Pushed the message to a Datastore ( as CDATA XML Content ).
- Built additional flows for processing messages either from Dead Letter queue for Datastore.
If I have to predict the future, I would say at some point in the future , an enhancement of these packages from SAP will probably do the same. In a B2B world, a message that has been acknowledged to a partner needs to be handled., Asking you B2B Partner to resend the message will not go down well and building Custom Solutions is not the answer. The sincere hope is that a standard re-try button is enabled in the B2B Monitor from SAP. I am sure it will come soon but we cannot wait for it. Until then you have no choice but to copy the standard Flow and build your own external retry mechanisms. ( We will look at such alternates sometime soon).
Handling Retries on Trading Partner Management is a new feature from Dec 2023 on SAP TPM. It is a very simple and straight forward solution and default retries are now available and auto configured.
Retrigger of failed B2B message is not available in standard from SAP. The messages after Max Retries are Escalated and it is now upto you as a Customer to build your own Retry mechanisms – Either from Source or copy Standard Step 2 and Step 3 Iflows from SAP for your own customizations. This hopefully is addressed in a future enhancements but be aware of this limitation till then ( As of Dec 2023 and keep looking this space or SAP documentation if anything new pops up).
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 7 – EDI Functional Acknowledgements for Inbound EDI Messages
- 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 14 – Handling Bundled Incoming EDIs
- 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