I have more than 20 solutions to deploy or retract at the same time, Currently i doing the deployment/retract one by one and each deployment is required an iis reset and this causes around 20 minutes for the complete deployment/retract.Is there a way to deploy or retract multiple solutions in a single batch process. I am using .net to do the deployment.
Not sure about
There are two basic ways to deploy/retract multiple solutions on SharePoint 2010:
stsadm command ('The Old Way')
You can use stsadm commands to retract/deploy your solutions and put them in batch file. It can look something like this:
By stopping SharePoint 2010 Administration service (SPAdminV4) before executing this batch you will save some time (but not too much). Then again instead of retracting, deleting, adding and deploying you can use
PowerShell script ('The New Way')
PowerShell is very powerful (!) tool for scripting. IMHO you need to solve your deployment by using some PS script (eg. second link). Since I would need few more pages of text to explain everything I will just point you in right direction:
When retracting solutions from SharePoint 2010, it only does an App Pool recycle on the web application the solution is deployed to (if it is deployed to all applications, then each app pool will get recycled). SharePoint treats each retraction as a separate timer job and there isn't any way to change that behavior. So, after each retracted solution, the applicable app pools will be recycled.
I prefer to group the operations. So I start by retracting all solutions, delete them, run an application pool recycle and restart the owstimer (if there are timer jobs in any of the solutions), then add all solutions and deploy them.
I have been working on projects with upto 30 solution packages at we followed that pattern. It is slow, yes, but it works everytime. Also it is seems very import to only run one deployment job at any time. So we built a tool to check for the deployment timer job to be finished before continuing with the next deployment operation. Gary Lapointe has built this into his tools.
Again, it might seem awkward and time consuming but for this is the solution that works every time and on single server as well as farms with multiple front-ends.