Home Page › Forums › BizTalk 2004 – BizTalk 2010 › BizTalk R2 WCF-Net.Tcp Adapter Consumption Issues
- This topic has 5 replies, 1 voice, and was last updated 9 years, 3 months ago by
community-content.
-
AuthorPosts
-
-
August 19, 2008 at 3:28 AM #20433
II am having the issue that i receive NULL Response when i select WCFTCPADAPTER. What i had done is just made a Orchestration
which just sends Response in String Format. Then I Deploy and publish
the Project as a WCF Service after executing SVCUTILS.exe <WCF
Link> then it Generated 2 Files which is- App.Config
- BiztalkInstance.cs. (not Posted here, if it requires then please let me know)
here is the App.Config File
<b>
<?xml version=”1.0″ encoding=”utf-8″?>
<configuration>
<system.serviceModel>
<bindings>
<netTcpBinding>
<binding name=”NetTcpBinding_ITwoWayAsync” closeTimeout=”00:01:00″
openTimeout=”00:01:00″ receiveTimeout=”00:10:00″ sendTimeout=”00:01:00″
transactionFlow=”false” transferMode=”Buffered” transactionProtocol=”OleTransactions”
hostNameComparisonMode=”StrongWildcard” listenBacklog=”10″
maxBufferPoolSize=”60000000″ maxBufferSize=”60000000″ maxConnections=”10″
maxReceivedMessageSize=”60000000″>
<readerQuotas maxDepth=”32″ maxStringContentLength=”8192″ maxArrayLength=”16384″
maxBytesPerRead=”4096000″ maxNameTableCharCount=”16384″ />
<reliableSession ordered=”true” inactivityTimeout=”00:10:00″
enabled=”false” />
<security mode=”None”>
<transport clientCredentialType=”Windows” protectionLevel=”None” />
<message clientCredentialType=”Windows” />
</security>
</binding>
</netTcpBinding>
</bindings>
<client>
<endpoint address=”net.tcp://muhammad-zaidi.pk.ubl.int:9002/WCFTEST”
binding=”netTcpBinding” bindingConfiguration=”NetTcpBinding_ITwoWayAsync”
contract=”WCFServiceTesting_WcfTesting_Port_1″ name=”NetTcpBinding_ITwoWayAsync” />
</client>
</system.serviceModel>
</configuration></b>
In Biztalk Server Console i made Receive Location configuaration as follows.
- Type: WCF-NETTCP
- Receive Handler: WCFTCPHOST
- Receive pipeline: PassThruReceive (I have Tried All types but not working in any of those)
- Send pipeline: PassThruTransmit (I have Tried All types but not working in any of those)
- General Tab –> Configure Button
- General Tab –> Address (URI): net.tcp://localhost:9002/WCFTEST
- Security Tab –> Security: None
- Message Tab –> InBound BizTalk message Body (Option Button Set to ) : Body Contents of <Soap Body> Element
- Message Tab –> OutBound WCF message Body (Option Button Set to ) : Body — Biztalk Response message Body
- Message Tab –> Marked Checked on Both Error check boxs.
The Client Side Code is as Follows
<b>Code SnippetWCFServiceTesting_WcfTesting_Port_1Client client = new WCFServiceTesting_WcfTesting_Port_1Client();
WcfTest ts = new WcfTest();
ts.Parameter1 = “Razi”;
client.Open();
MessageBox.Show(client.Operation_1(ts));
client.Close();</b>
-
August 19, 2008 at 5:39 AM #20434
Try this. In the BizTalk admin console, stop the orchestration. Now run your client. Now run a query for “All service instances” in the group hub page. You should have a suspended message. Open up the message to make sure the data was received correctly. If the data is right, you can right click on the messae and resume in debug mode. Right click again and open the message in the orchestration debugger. Now you can add breakpoints, step through, and check the values of variables and messages. Alternatively, you could just use a Sysem.Diagnostics.Trace.WriteLine() statement to print out the return value. Then you can view the trace statement in DebugView.
-
August 19, 2008 at 11:40 PM #20444
Thanx for the Response Rusell. I have tried your both technoques to debug. Finally the conclusion is that. it Passes through Conctruct Messages and Sends Message through Orchestration in Debug mode.
but i received 2 messages in 1 message it RETURNS=”Successfully Send a Message (My String Message)”;
in second message in after debug is an error .. which is :
<SOAP:Envelope xmlns:SOAP=”http://schemas.xmlsoap.org/soap/envelope/” SOAP:encodingStyle=”http://schemas.xmlsoap.org/soap/encoding/”><SOAP:Body><SOAP:Fault><faultcode>Microsoft BizTalk Server Negative Acknowledgment </faultcode><faultstring>An error occurred while processing the message, refer to the details section for more information </faultstring><faultactor>net.tcp://localhost:9002/WCFTEST</faultactor><detail><ns0:NACK Type=”NACK” xmlns:ns0=”http://schema.microsoft.com/BizTalk/2003/NACKMessage.xsd”><NAckID>{B4D96C2F-1B0D-4B1A-8560-386FF9E92365}</NAckID><ErrorCode>0xc0c016b7</ErrorCode><ErrorCategory>0</ErrorCategory><ErrorDescription>System.ApplicationException: The response message body was not read. (This may indicate the connection has been closed.)</ErrorDescription></ns0:NACK></detail></SOAP:Fault></SOAP:Body></SOAP:Envelope>
-
August 20, 2008 at 4:57 AM #20450
What do you mean when you say you received 2 messages in 1? If you just run the process without debugging, are there any resulting suspended messages?
-
August 20, 2008 at 9:17 PM #20455
I excuse about that Error Message which posted in my previous post.
That Error message came because i was in degug mode quite for a long
while. so it was timeout error thats why that error occurs in run Query mode.
Kindly Ignore my previous Post.Let me explain further. When i execute the process without debugging. The process first entered in Orchestration–> Entered in Expression Box (seen in Event viewer by (Diagnositc Command)) –> Entered in Construct Message (seen in Event viewer by (Diagnositc Command)) but i don’t received my actual send message(Response Message) in my client code but rather i received NULL message. I didn’t found any errors in Event Viewer but only found the Tracing Messages e.g. (“Entered in Expression Box”) and (“Entered in Construct Message”) which displayed succesffuly in Event VIewer.
Then I use debugged method by HAT technique which you told me to do.
After Running a Query I successfully get the Response Message. but i don’t understand why i don’t receive that message in my client.
Is this any thing Wrong in my client code??? or In my Receive Location Setting?? I suspects, i m missing some settings in Receive Location .. may be in In/Out Bound WCF Message Part.
Your help is highly appreciated.
Thanks
Regards
Razi
-
August 21, 2008 at 5:13 AM #20462
Try this. What is the message type of the response message that you are sending to the client? Create a file send port and add the following filter: BTS.MessageType = “http://<response message namespace>#<root node name>. Now run the process again. Did the file send port pick up the response message to the client? Did it contain any data?
-
-
-
-
-
-
AuthorPosts
- The forum ‘BizTalk 2004 – BizTalk 2010’ is closed to new topics and replies.