I have an ASP.NET 3.5 application that started in 1.1 and has been ported from IIS5 to IIS6 and now we're going to IIS7. Back in the 1.1 days we implemented URL-rewriting functionality based on HTTP Modules that still works great - fairly complex logic that is very stable. It allows us to take URL's like this
www.abc.com/merchant
and figure out that 'abc' represents a brand of products and 'merchant' is one of many companies that sell that brand. So far so good.
Along the way we have had some merchants close, others merge, etc. To preserve the URL's for them, we will sometimes use IIS6's virtual-directory-redirection capability to redirect www.abc.com/oldMerchant to www.abc.com/newMerchant, or to something else entirely, like www.micorsoft.com - who knows. There are about a dozen of these now.
I am trying to do the same in IIS7 and I've found many posts describing differnet mechanisms (like this). The biggest problem I have is that in IIS7 the virtual root paths STILL go thru my URL rewrite logic, while they didn't in IIS6. That is, instead of redirecting www.abc.com/oldMerchant to www.abc.com/newMerchant, the URL rewriting sees it first and concludes that oldMerchant isn't a valid merchant (as it should).
Before I go down a coding road to solve this problem, does someone know of a magical switch I've missed?