VS 2008, Web service and Extremely Slow Build

  • Thread starter Thread starter Chris Botha
  • Start date Start date
C

Chris Botha

I have a Web Service with approx 90 functions.
I had, or still have, a VS 2005 Windows app that has a reference to the Web
Service and when building the Windows app it takes a few seconds to build
the release or debug.

Create a VS 2008 Windows app with only 1 form and a "hello world" button on
the form, and building is blinding fast.
Now add a Web Reference to the Web Service, and the app takes longer than 1
minute to build, release or debug.
Make one change to the source file of the form, for example add a comment
line, and the build takes a minute again.

I don't know what it is doing, as during the build the CPU usage is 25% or
lower, RAM usage less than 50% of the RAM (quad AMD with 3 gig RAM).
 
Well, I don't know the cause here - but perhaps create the
web-reference code manaually (not inside VS) via wsdl.exe,
wse3wsdl.exe or svcutil.exe? Then it doesn't recreate until you want
it to...

If the web-service is in the same sln, you might also want to try
using a web-application project for the web-service; in my experience
these buold a lot quicker than the web-site equivalents. (this only
applies if the time is being used building the web-service).

Marc
 
Chris Botha said:
I don't know what it is doing, as during the build the CPU usage is 25% or
lower, RAM usage less than 50% of the RAM (quad AMD with 3 gig RAM).

I don't have an answer to the main question (why the build is so slow),
but the fact that CPU usage is 25% and you have a quad CPU seems to indicate
that the compiler is running a single thread, so it is only using one of
your four CPUs, and it is working at 100% of the capability of that one CPU.
So yes, it is busy during all the time that your compilation is taking.
 
Thanks, I used the wsdl.exe program, no joy though, exactly the same
results, the build takes more than a minute.

The following sucks, but at least I can work.
I create a separate assembly, it only references the Web Service (or it uses
the proxy generated by wsdl.exe - both works).
Then the original app references this new assembly and call the Web Service
through the new assembly, so where the call previously was for example
TheWebService.GetCustomers()
it is now
NewAssembly.TheWebService.GetCustomers()

When the Web Service changes, then rebuilding the new assembly takes a
minute, but building the main app after this is as fast as expected.

Geez ...
 
Back
Top