Home Page › Forums › BizTalk 2004 – BizTalk 2010 › Has anyone successfully performed BAPI_TRANSACTION_COMMIT/BAPI_TRANSACTION_ROLLBACK using the R2 SAP LOB Adapter from a Dynamic send port in an orchestration?
- This topic has 1 reply, 1 voice, and was last updated 9 years, 3 months ago by
community-content.
-
AuthorPosts
-
-
April 16, 2009 at 6:30 AM #22151
Is it possible to perform BAPI transaction commit/rollback using dynamic ports defined in an orchestration using the BT LOB Adapter for SAP?
I can execute BAPIs against the dynamic port in my orchestration but when subsequently calling BAPI_TRANSACTION_COMMIT or BAPI_TRANSACTION_ROLLBACK from the same orchestration I am getting “The Inner Channel to use was not found for the key.” error. I am using the same dynamic port for initial BAPI call and the commit/rollback operation. I used the SAPTransaction code sample as a go-by with only difference being the port type set to dynamic instead of Specify Later. The connection address for the port, action, binding type, binding configuration and credentials are all being assigned in the orchestration instead…
Dynmaic Port Setup
———————-
SAPPort(Microsoft.XLANGs.BaseTypes.Address) = “sap://CLIENT=***;LANG=EN;@b/*****/***?GROUP=******&RfcSdkTrace=False&AbapDebug=False”;
SAPPort(Microsoft.XLANGs.BaseTypes.TransportType) = “WCF-Custom”;Initial BAPI Message
———————–
BAPIRequestMsg(Microsoft.Adapters.SAP.BiztalkPropertySchema.ConnectionState) = “OPEN”;
BAPIRequestMsg(WCF.BindingType) = “sapBinding”;
BAPIRequestMsg(WCF.Action) = “http:Microsoft.LobServices.Sap/2007/03/Rfc/<BAPI_NAME>”;
BAPIRequestMsg(WCF.UserName) = “user”;
BAPIRequestMsg(WCF.Password) = “pass”;
BAPIRequestMsg(WCF.BindingConfiguration) = “<binding name=\”SAPBinding\” closeTimeout=\”00:01:00\”” +
” openTimeout=\”00:01:00\” receiveTimeout=\”00:10:00\” sendTimeout=\”00:01:00\”” +
” enableBizTalkCompatibilityMode=\”true\” receiveIdocFormat=\”Typed\”” +
” enableSafeTyping=\”true\” generateFlatFileCompatibleIdocSchema=\”true\”” +
” maxConnectionsPerSystem=\”100\” enableConnectionPooling=\”true\”” +
” idleConnectionTimeout=\”00:15:00\” flatFileSegmentIndicator=\”SegmentDefinition\”” +
” enablePerformanceCounters=\”false\” autoConfirmSentIdocs=\”true\”” +
” enableBusinessObjects=\”false\” acceptCredentialsInUri=\”false\”” +
” padReceivedIdocWithSpaces=\”false\” sncLibrary=\”\” sncPartnerName=\”\” />”BAPI Commit Message
————————-
BAPICommitMsg(Microsoft.Adapters.SAP.BiztalkPropertySchema.ConnectionState) = “CLOSE”;
BAPICommitMsg(WCF.BindingType) = “sapBinding”;
BAPICommitMsg(WCF.Action) = “http:Microsoft.LobServices.Sap/2007/03/Rfc/BAPI_TRANSACTION_COMMIT”;
BAPICommitMsg(WCF.UserName) = “user”;
BAPICommitMsg(WCF.Password) = “pass”;
BAPICommitMsg(WCF.BindingConfiguration) = “<binding name=\”SAPBinding\” closeTimeout=\”00:01:00\”” +
” openTimeout=\”00:01:00\” receiveTimeout=\”00:10:00\” sendTimeout=\”00:01:00\”” +
” enableBizTalkCompatibilityMode=\”true\” receiveIdocFormat=\”Typed\”” +
” enableSafeTyping=\”true\” generateFlatFileCompatibleIdocSchema=\”true\”” +
” maxConnectionsPerSystem=\”100\” enableConnectionPooling=\”true\”” +
” idleConnectionTimeout=\”00:15:00\” flatFileSegmentIndicator=\”SegmentDefinition\”” +
” enablePerformanceCounters=\”false\” autoConfirmSentIdocs=\”true\”” +
” enableBusinessObjects=\”false\” acceptCredentialsInUri=\”false\”” +
” padReceivedIdocWithSpaces=\”false\” sncLibrary=\”\” sncPartnerName=\”\” />”If I change the orchestration to bind to physical ports by changing the port type to “Specify Later” just like in the SAPTransaction sample, I was able to make the BAPI call and the subsequent Commit/Rollback call also. This is why I ask if the same is possible through dynamic ports?
P.S. I have a specific WCF-Custom host created that is used for both Send and Receive. The test server is a single server and is not clustered or load-balanced.
-
April 16, 2009 at 3:32 PM #22153
Hi,
I’ve done it with “Direct Binding” using “Routing between ports via filters on MessageBox”. It works well.
As an additional benefit, I can easily reconfigure SAP Port in Admin Console depending on environment I want to use.
-
-
AuthorPosts
- The forum ‘BizTalk 2004 – BizTalk 2010’ is closed to new topics and replies.