views:

27

answers:

2

I have a ps1 script that deploys all of my webparts. I started noticing an error (Error 503 service unavailable) after running Update-SPSolution. What is happening is that when I upgrade all my webparts, the application pools for all SharePoint web applications stop. It also takes about 12 minutes per web part to deploy (which seems like forever - it looks like it may be running them all in parallel). Could someone shed some light as to what the best way is to upgrade web parts using Update-SPSolution. Optimally, I would like my script to stop while it fully completes an upgrade on a particular web part, and then move on the next one when it is finished. Thoughts?

A: 

If your solutions are Farm solutions, SharePoint will restart the application pool in order to reload your assemblies.

The only way to completely remove this restart is to use Sandbox solution. That's not always possible, but depending on your type of customization this may be an answer.

Another solution is to only have one solution containing all your webparts. You'll still need an application pool restart, but it should take less than a minute.
12min is really a lot!

Edit:
To merge your WSPs, you'll have to merge your Visual Studio projects into one. It's also possible to do it by hand, but it's not a good choice in the long term.

Nico
How can I create one wsp from all the wsp's?
Josh
A: 

You might get better performance on the upgrade if you set ResetWebServer to false in each solution manifest. Naturally, you would be compelled to reset the web server(s) after all the upgrades, but at least you would only be required to do it once.

You might also consider combining web parts into fewer projects/solutions. This can be challenging, as your web parts' assembly-qualified names are part of the .webpart file, and therefore part of any web part that is still in use.

kbrimington