Technology Blogs by SAP
Learn how to extend and personalize SAP applications. Follow the SAP technology blog for insights into SAP BTP, ABAP, SAP Analytics Cloud, SAP HANA, and more.
cancel
Showing results for 
Search instead for 
Did you mean: 


You create a scenario using specific adapter. There are a large volume of messages processed in this scenario. To avoid many messages in To be delivered status and processed slowly, you need to assign sufficient work threads. You may be wondering how to increase the value of Maximum Number of Threads for a specific adapter / a specific queue (for example, SOAP_http://sap.com/xi/XI/SystemCall). Here I will introduce how to tune the queue comsumer threads for different adapters in PI/PO system.

1) For some normal adapters (SOAP, RFC, JDBC, JMS, File, HTTP_AAE, IDoc_AAE......), you can add a new property set for the specific Adapter in the property "messaging.connectionDefinition". This is appended after the global AFW entry.

You can set the custom value for property "messaging.connectionDefinition" in

 

-> NWA

-> Configuration

-> Infrastructure

-> Java System properties

-> Services

-> XPI Service: AF Core



or

-> ConfigTool (- \usr\sap\<SID>\<Instance ID>\j2ee\configtool)

-> template - Usage_Type_All_in_One

-> services

-> com.sap.aii.af.svc



****Please restart the system after saving these changes in NWA or in ConfigTool. Then the change will take effect and the Maximum Number of Threads for these adapters in Engine Status will be updated as expected.*****

  • For example, increasing the value of Call.maxConsumers for SOAP adapter from default value 5 to 10


(name=global, messageListener=localejbs/AFWListener, exceptionListener=localejbs/AFWListener, pollInterval=60000, pollAttempts=60,

Send.maxConsumers=5, Recv.maxConsumers=5, Call.maxConsumers=5, Rqst.maxConsumers=5) (name=SOAP_http://sap.com/xi/XI/System,  messageListener=localejbs/AFWListener, exceptionListener=localejbs/AFWListener, pollInterval=60000, pollAttempts=60,  Send.maxConsumers=5, Recv.maxConsumers=5, Call.maxConsumers=10, Rqst.maxConsumers=5)

  • For example, increasing the value of maxConsumers for all the queues of File adapter from 5 to 8


(name=global, messageListener=localejbs/AFWListener, exceptionListener=localejbs/AFWListener, pollInterval=60000, pollAttempts=60,  Send.maxConsumers=5, Recv.maxConsumers=5, Call.maxConsumers=5, Rqst.maxConsumers=5) (name=File_http://sap.com/xi/XI/System,  messageListener=localejbs/AFWListener, exceptionListener=localejbs/AFWListener, pollInterval=60000, pollAttempts=60,  Send.maxConsumers=8, Recv.maxConsumers=8, Call.maxConsumers=8, Rqst.maxConsumers=8)

****Please pay attention to the name part, it would be better to check the correct adapter name in Engine status. It should be case-insensitive. If you use the name=FILE_http://sap.com/xi/XI/System, the custome value can be saw in NWA or in ConfigTool, however it does not really take effect and the Maximum Number of Threads for File adapter in Engine Status will not be updated as expected.*****

  • For example, increasing the value of Send.maxConsumers for SFTP adapter from 5 to 10


(name=global, messageListener=localejbs/AFWListener, exceptionListener=localejbs/AFWListener, pollInterval=60000, pollAttempts=60,  Send.maxConsumers=5, Recv.maxConsumers=5, Call.maxConsumers=5, Rqst.maxConsumers=5) (name=SFTP_http://sap.com/xi/XI/SFTP, messageListener=localejbs/AFWListener, exceptionListener=localejbs/AFWListener, pollInterval= 60000, pollAttempts=60, Send.maxConsumers=10, Recv.maxConsumers=5, Call.maxConsumers=5, Rqst.maxConsumers=5)

****Please pay attention to the name part, it would be better to check the correct adapter name in Engine status. It should be "name=SFTP_http://sap.com/xi/XI/SFTP", not "name=SFTP_http://sap.com/xi/XI/System".****

 

  • For example, increasing the value of maxConsumers for File adapter and SFTP adapter together


 

(name=global, messageListener=localejbs/AFWListener, exceptionListener=localejbs/AFWListener, pollInterval=60000, pollAttempts=60,  Send.maxConsumers=5, Recv.maxConsumers=5, Call.maxConsumers=5, Rqst.maxConsumers=5) (name=File_http://sap.com/xi/XI/System,  messageListener=localejbs/AFWListener, exceptionListener=localejbs/AFWListener, pollInterval=60000, pollAttempts=60,  Send.maxConsumers=8, Recv.maxConsumers=8, Call.maxConsumers=8, Rqst.maxConsumers=8) (name=SFTP_http://sap.com/xi/XI/SFTP, messageListener=localejbs/AFWListener, exceptionListener=localejbs/AFWListener, pollInterval= 60000, pollAttempts=60, Send.maxConsumers=10, Recv.maxConsumers=5, Call.maxConsumers=5, Rqst.maxConsumers=5)

 



 

2) For Integrated Configuration Object (ICO) scenarios, the message processing occurs exclusively in the MS Sender queues (Send.maxConsumers for asynchronous outbound and Call.maxConsumers for synchronous outbound). To ensure sufficient work threads, you can consider to increase the number of Send.maxConsumers and Call.maxConsumers for specific adapter. The value of Recv.maxConsumers and Rqst.maxConsumers will not be considered in ICO scenarios.

 

*******

Related Notes/Documents:

 

SAP Note 1623356 - "To be delivered" messages in Adapter Engine

SAP Note 1557036 - Integrated Configuration Objects (ICO) scenarios use Messaging System Sender Queues only

Messaging System queue properties after XI 3.0 SP19 / XI 7.0SP11

2 Comments