Our TeamCity server needs a hardware upgrade, so we have to shut it down for a while.
However, we've 30 agents, and 10 teams using it, so to find a period when no agents are running builds is near impossible.
I'm hoping that I could stop/start the server whilst builds are running, and TC would be clever enough that the build agents continue their builds during the server downtime, and that they re-register in their running state once the server is back up.
Does anyone know if this is a correct assumption, or does a server restart cause all builds to stop?
I know for certain that you can restart the TeamCity Web Server while agents are running builds. The agents will reregister when the web server comes back up, the builds will not be terminated. However, I'm not sure how long it retries for when a build has finished. Our builds take around an hour so it was always easy to find a small window of time while builds are running.
The problem you'll run into is that short running builds means you have little time you can take it down.
If you are able to schedule downtime for TeamCity out of business hours that would be the easiest. What do you do when you upgrade the TeamCity software version?
TeamCity will also rerun builds if they were automatically cancelled because an agent went offline for too long. This can take a while, or will happen quickly if the original agent reregisters and doesn't state it is running that build.