Re: .net class as message

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



there is definitely a cost associated in .NET serialization and Deserialization. It's all about whether that cost is within your SLA to tolerate.

When you first use the XmlSerializer against a given type, a dynamic class is created and compiled on the fly to represent the serialized class.

You can avoid this dynamic gen and compile step by using sgen.exe, which enables your to pregenerate serialization assemblies and deploy this on your server to avoid the dynamic gen and compile.

--
Regards,
Saravana Kumar [MVP - BizTalk Server]
http://www.biztalk247.com/v1/
http://www.digitaldeposit.net/blog

"DNova" <dnova7@xxxxxxxxx> wrote in message news:06fa6e15-cdb2-42da-9c1d-cda023ca654d@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
As long as you don't a ton of messages flying around (like thousands
at once) you should be fine. The main issue is that the serializer is
going to completely instantiate the object, meaning it wont stream
like messages in biztalk do. This streaming keeps BizTalk's memory
foot print very stable as only parts of a message are loaded into
memory at any one time. I do this alot with no side effects. The
only one I've ever had was on a server that would throw these like
carriage returns or some extended character in the message and then it
would sometimes not have the whole message. I think it was an
unpatched server. I posted about it on this group two weeks ago.
That said, I still do this a lot with no problems.

Oh also, if you don't want a .NET class your helper method can take
XmlDocument or the message interface. By default these will both pass
by ref and you can sneak in and change values behind BizTalk's back.
This will preserve your promoted properties though so will
NewMessage(*) = OldMessage(*) at the end of your orchestration.

I hope this helps some, if you have more questions please feel free to
ask.

Kind Regards,
-Dan

.



Relevant Pages

  • Re: delegate question
    ... information of the method that the delegate is attached to. ... the server, and never get to you (a copy of your client will be sent to the ... event is remoted back to the client, ... the> client-runtime throws serialization exceptions of classes that are not> relevant for my client. ...
    (microsoft.public.dotnet.framework.remoting)
  • RE: Session management on web farm with sql server
    ... For serialization, since winform/desktop application can hold most objects ... based) and may work between client and server machines, ... the approach i use for complex objects I store in session, ... serialization/deserialization in sql server, the reference to the ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: GC, Windows or Design problem?
    ... this amount of memory (don't know how large it ... managed heap cannot grow to accommodate the collection. ... why did it work on the server? ... collection of that size, during serialization, the GC heap could shrink ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Problem with serializing business object instead of core objec
    ... do this since the server does not need to know the type of object I am ... > server assembly and once in the client assembly. ... > client and server assemblies. ... >> an object instead of allowing the framework to handle the serialization so ...
    (microsoft.public.dotnet.framework.remoting)
  • Re: Web service calls...
    ... If you're making webservice calls across appdomains/application pools the ... webservice is that you dont incurr the cost of xml serialization. ...
    (microsoft.public.dotnet.framework.webservices)