Use Performance Counters with the SAP adapter
Microsoft BizTalk Adapter Pack clients can use performance counters to gauge the performance of the adapters. The BizTalk Adapter Pack setup program creates the performance counter category "Microsoft BizTalk Adapter for mySAP Business Suite" along installing the BizTalk Adapter Pack.
LOB Time (Cumulative) Performance Counter
The BizTalk .NET Adapter for SAP category has one performance counter called the "LOB Time (Cumulative)". This performance counter denotes the time, in milliseconds, that the LOB client library takes to complete an action that the adapter initiates. The SAP adapter creates an instance of the performance counter in the following pattern:
<process id>:<app domain id>:<endpoint id>:<action id>
The endpoint ID could be:
For calls from the adapter to the SAP system (outbound)
A,<application server host>,<system number>
B,<message server host>,<R3NAME>
D,<destination>
For calls from the SAP system to the adapter (inbound)
I,<gateway host>,<gateway server>
ID,<destination>
The action ID could be:
<RFC name> (for an RFC call)
T,<RFC name> (for a tRFC call)
The performance counter is initialized only after the adapter makes the first call to the SAP system. Also, the InstanceLifetime property of the performance counter is set to 'Process', which means that the performance counter ceases to exist as soon as the program that creates the counter terminates.
Note
The precision of the LOB Time (Cumulative) performance counter is 16 milliseconds.
Enabling Performance Counters
The performance counters can be enabled or disabled by setting the binding property EnablePerformanceCounters. To enable performance counters, set the EnablePerformanceCounters binding property to True. To disable performance counters, set EnablePerformanceCounters to False. By default, EnablePerformanceCounters is set to False.
Performance Counters and the WCF LOB Adapter SDK
Changing the value of the EnablePerformanceCounters binding property also changes the value of the corresponding performance counter for the WCF LOB Adapter SDK. Also, the binding property for the WCF LOB Adapter SDK is static, whereas that for the BizTalk Adapter Pack is dynamic. Hence, if there are two instances of the SAP adapter binding in the AppDomain, and the EnablePerformanceCounters binding property is set to True in one and False in the other, the adapter-specific performance counter will be enabled in one and disabled in the other. However, because the binding property for WCF LOB Adapter SDK is static, it will either be set to True or False depending on what value was specified last.