1

I'm not sure if this is the best/correct place for this type of question. But I have an existing .NET website which I am moving from our dedicated EC2 server to an Azure Web App.

However, this current site uses an .htaccess file with about 200 redirects (301 from old urls to new ones) which is powered by ISAPI rewrite (Which was installed manually on the Win2008 server).

I need to keep these redirects, but wondering how everyone else deals with permanent Url redirects on .NET applications when moving to an Azure Web App (From a dedicated server that had ISAPI rewrite installed)?

Putting them all in the web.config seems a little odd to me? And I don't know how that would affect performance?

Any advice or pointers would be appreciated as always.

YodasMyDad
  • 9,248
  • 24
  • 76
  • 121

1 Answers1

2

I always put them in the web.config.
If you think it will be too messy, you can put them in a separate file and use the configSource attribute to link to the file.

azzlack
  • 1,191
  • 1
  • 9
  • 28
  • How many is the most you have had in there? Did you notice any performance issues? – YodasMyDad Jun 08 '15 at 11:00
  • The most I've had was something between 100 and 200, but that was done with [Rewrite Maps](http://www.iis.net/learn/extensions/url-rewrite-module/using-rewrite-maps-in-url-rewrite-module). We didn't measure the performance, but the site is not slow today so my guess is it does not impact performance much. – azzlack Jun 08 '15 at 11:09
  • Also, 301 redirects will be cached by the browser, so the user will not get redirected after the first visit. The browser will translate the url before the request is sent. – azzlack Jun 08 '15 at 11:10