What is the technique for serving the website offline message?
Do they have a different IIS site that takes charge on the deploy action?
What is the technique for serving the website offline message?
Do they have a different IIS site that takes charge on the deploy action?
I'm pretty sure I asked a similar question on Stack Overflow regarding how to implement such a thing.
The answer was quite simple: all you have to do is add an HTML file to the root directory of an IIS application that is named app_offline.htm
. Once this is done, any users who request something are shown that page.
If I'm not mistaken, that's how Stack Overflow does it.
Of course, there are other ways of approaching this problem, but this seems the most straight-forward.
Basically, when StackOverflow goes offline, the server puts up a static webpage telling us all that it is down for maintenance.
Then, the server searches through its database and absorbs some of the awesomeness that Jon Skeet has rubbed off on the website and uses it to make changes that benefit the website.
$('#jon-skeet').absorb();
The problem is, too much of a good thing can be bad. So just before the server absorbs too much of Jon's awesomeness, it stops and comes back online. It will then repeat this process a week or two later.