Orchestartion Skipping Call to .NET Assembly
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > BizTalk Server > BizTalk Server Orchestration > Orchestartion Skipping Call to .NET Assembly




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Orchestartion Skipping Call to .NET Assembly  
Tomms


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
07-29-04 07:47 AM


Hi All,

I have an Orchestartion that Calls a .Net Assembly(Serializable) in
Expression Shape for SQl Update .The Process works fine when i receive 100
Messages(Single Message size 3KB) at a time but Skips call to .NET
Assembly when there are like 200 Messages
Is this kind of some  Leakage...how can i debug this

####.Net Assembly
[Serializable]
public class Test_Resp
{
public Test_Resp()
{
//
// TODO: Add constructor logic here
//
}


public void parse_conf_no(XmlDocument msg_in,ref string conf_no,ref
string error,ref string date_time,ref string loris_id)
{

string db_up_error="";

XmlNamespaceManager nsm = new XmlNamespaceManager(msg_in.NameTable);
nsm.AddNamespace("ns0","http://Test.Test_Response");

XmlNode root= msg_in.SelectSingleNode("ns0:Test_Resp",nsm);
try
{

XmlNode nodeA = root.SelectSingleNode("ns0:Test_Error",nsm);

error=nodeA.InnerText;
}
catch
{
error = "Cannot Parse Test_Error";
}
try
{
XmlNode nodeA = root.SelectSingleNode("ns0:Test_Confirm_No",nsm);

conf_no=nodeA.InnerText;

}
catch
{
conf_no="No Parse";
}

try
{
XmlNode nodeA = root.SelectSingleNode("ns0:Test_Date_Time",nsm);

date_time=nodeA.InnerText;

}
catch
{
date_time = "No Parse";
}

try
{
XmlNode nodeA = root.SelectSingleNode("ns0:Test_ID",nsm);

loris_id=nodeA.InnerText;

}
catch
{
loris_id= "0";
}

db_up_error=update_DB(loris_id,conf_no, error,date_time);

}


string update_DB(string rli_ros,string cfn_ros,string err_ros,string
dti_ros)
{
string ret_str="";
string SQL_str = "Update_DB";
string connString="Data Source=TEST_SHARE;Integrated
Security=SSPI;Initial Catalog=Test";
using(SqlConnection con_up= new SqlConnection(connString))
{
SqlCommand cmd_up = new SqlCommand(SQL_str,con_up);

try
{
cmd_up.CommandType=CommandType.StoredProcedure;

cmd_up.Parameters.Add("@ID_1",SqlDbType.Int).Value =
System.Convert.ToInt32(rli_ros);
cmd_up.Parameters.Add("@Node_3",SqlDbType.VarChar,20).Value=cfn_ros;
cmd_up.Parameters.Add("@Node_4",SqlDbType.VarChar,250).Value=err_ros;
cmd_up.Parameters.Add("@Node_9",SqlDbType.VarChar,50).Value=dti_ros;

con_up.Open();
cmd_up.ExecuteNonQuery();
ret_str="UpDated Test DB with Conf_No from Local";
}
catch
{
ret_str="Error in Updating Test DB";
}
finally
{
con_up.Close();

}
}

return ret_str;
}


}



Thanks,






[ Post a follow-up to this message ]



    RE: Orchestartion Skipping Call to .NET Assembly  
Berit


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
07-29-04 07:47 AM

I am sorry but I can not help you but I have an additional question on how y
ou in detail write the code in the expression in the orch to pass the XmlDoc
ument to your own method. I have tried this :
xmlDoc = My_Msg;
BTSSNClasses.MessageLogInfo.AddMessageLogPortNot(xmlDoc);

I have declare xmlDoc as a variable of the type System.Xml.XmlDocument

My_Msg is the orch message

The orch compiles, but I get this error in runtime:
Object reference not set to an instance of an object.

Exception type: NullReferenceException
Source: BTSSNClasses
Target Site: Void AddMessageLogPortNot(System.Xml.XmlDocument)

Thank you very mych if you can help
--
Regards Berit


"Tomms" wrote:

>
> Hi All,
>
>  I have an Orchestartion that Calls a .Net Assembly(Serializable) in
> Expression Shape for SQl Update .The Process works fine when i receive 100
> Messages(Single Message size 3KB) at a time but Skips call to .NET
> Assembly when there are like 200 Messages
> Is this kind of some  Leakage...how can i debug this
>
> ####.Net Assembly
> [Serializable]
> public class Test_Resp
> 	{
> 		public Test_Resp()
> 		{
> 			//
> 			// TODO: Add constructor logic here
> 			//
> 		}
>
>
> 		public void parse_conf_no(XmlDocument msg_in,ref string conf_no,ref
> string error,ref string date_time,ref string loris_id)
> 		{
>
> 			string db_up_error="";
>
> 			XmlNamespaceManager nsm = new XmlNamespaceManager(msg_in.NameTable);
> 			nsm.AddNamespace("ns0","http://Test.Test_Response");
>
>             XmlNode root= msg_in.SelectSingleNode("ns0:Test_Resp",nsm);
> 			try
> 			{
>
> 				XmlNode nodeA = root.SelectSingleNode("ns0:Test_Error",nsm);
>
> 				error=nodeA.InnerText;
> 			}
> 			catch
> 			{
> 				 error = "Cannot Parse Test_Error";
> 			}
> 			try
> 			{
> 				XmlNode nodeA = root.SelectSingleNode("ns0:Test_Confirm_No",nsm);
>
> 				conf_no=nodeA.InnerText;
>
> 			}
> 			catch
> 			{
> 				conf_no="No Parse";
> 			}
>
> 			try
> 			{
> 				XmlNode nodeA = root.SelectSingleNode("ns0:Test_Date_Time",nsm);
>
> 				date_time=nodeA.InnerText;
>
> 			}
> 			catch
> 			{
>                date_time = "No Parse";
> 			}
>
> 			try
> 			{
> 				XmlNode nodeA = root.SelectSingleNode("ns0:Test_ID",nsm);
>
> 				loris_id=nodeA.InnerText;
>
> 			}
> 			catch
> 			{
> 				loris_id= "0";
> 			}
>
> 			  db_up_error=update_DB(loris_id,conf_no, error,date_time);
>
> 		}
>
>
> 		string update_DB(string rli_ros,string cfn_ros,string err_ros,string
> dti_ros)
> 		{
> 			string ret_str="";
> 			string SQL_str = "Update_DB";
> 			string connString="Data Source=TEST_SHARE;Integrated
> Security=SSPI;Initial Catalog=Test";
> 			using(SqlConnection con_up= new SqlConnection(connString))
> 			{
> 				SqlCommand cmd_up = new SqlCommand(SQL_str,con_up);
>
> 				try
> 				{
> 					cmd_up.CommandType=CommandType.StoredProcedure;
>
> 					cmd_up.Parameters.Add("@ID_1",SqlDbType.Int).Value =
> System.Convert.ToInt32(rli_ros);
> 					cmd_up.Parameters.Add("@Node_3",SqlDbType.VarChar,20).Value=cfn_ros;
> 					cmd_up.Parameters.Add("@Node_4",SqlDbType.VarChar,250).Value=err_ros;
> 					cmd_up.Parameters.Add("@Node_9",SqlDbType.VarChar,50).Value=dti_ros;
>
> 					con_up.Open();
> 					cmd_up.ExecuteNonQuery();
> 					ret_str="UpDated Test DB with Conf_No from Local";
> 				}
> 				catch
> 				{
> 					ret_str="Error in Updating Test DB";
> 				}
> 				finally
> 				{
> 					con_up.Close();
>
> 				}
> 			}
>
> 			return ret_str;
> 		}
>
>
> 	}
>
>
>
> Thanks,
>
>





[ Post a follow-up to this message ]



    RE: Orchestartion Skipping Call to .NET Assembly  
Tomms


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
07-29-04 10:50 PM

Hi Berit,

Parse is the object of the Class Test_Resp, under Variables in Orch.

Test_Response_1 is the Msg you recieve and all other parameters are
strings


Expression Shape
-----------------------------------------
Parse = new Test_Resp.Ros_Resp();
Parse.parse_conf_no(Test_Response_1,ref Conf_No,ref Error,ref
ros_date_time,ref ros_rip_lead_id);
--------------------------------------------

Regards,






[ Post a follow-up to this message ]



    Re: Orchestartion Skipping Call to .NET Assembly  
Tomms


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
07-29-04 10:50 PM

Hi Berit,

Check July 27 Post on

invoke c# classes from orchestrations

Regards,






[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 11:34 AM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register