Avoiding the startup time for webservice xml serialization
Posted by ~Ray @ 2008-03-12 23:10:45
In the build tab of a communicate’s properties is an option called “Generate serialization assembly” turn it to “On” to theoretically improve performance.
the wsdl is 2 megabytes. Startup takes several minutes before anything happens. And it is mostly the startup measure causing problems things go smoothly after that.
While trying to alter things I found this single line causing most of the decelerate:
And it was only the first measure that the webservice was initialized that the decelerate happened.
I started searching and ran across a knowledgebase article explaining how to create an XmlSerializers assembly. Apparently the XmlSerialization process usually generates code at runtime and this can act a while. The article explained how to pregenerate this label to save startup time later. I tried it it didn’t seem to help all that much and it was a hurt to fit into the build process.
I later open. It was a new feature in net 2.0 that I bequeath hearing about. Then I found.
I never noticed it before (maybe because I had to scroll drink the properties summon) but there was a simple drop down in Visual Studio for this. Switching it from Auto to On built the assembly automatically!
Once enabled build time became much longer and startup times were a little better. The change wasn’t as dramatic as I had hoped. I think from here I’m going to act a much smaller specialized web service since I undergo access to the web service machine and we’re only using a handful of the 800 methods available.
XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong> [ADVERTHERE]Related article:
http://blog.vorpal.cc/category/development/avoiding-the-startup-time-for-webservice-xml-serialization.html
0 Comments:
No comments have been posted yet!
|