Posts Tagged ‘SEO’

March 20th, 2010

The difference between Routing and Rewriting

As most of you are probably aware, if you read my blog enough, I am the sole developer of a URL Rewriter that I have tried to keep extensible and relevant to the problems that modern web developers face when exposing their applications to the web, by allowing them to have more control over the only interface that matters on the web … THE URL.  The benefits of a URL Rewriter have been explained many times, by many people, so I am not going to add just another rant to the web about keeping your URL’s clean for the search engines.  I will just leave you with Jeff’s explanation of why you shouldn’t ignore the URL.

Having multiple URLs reference the same content is undesirable not only from a sanity check DRY perspective, but also because it lowers your PageRank. PageRank is calculated per-URL. If 50% of your incoming backlinks use one URL, and 50% use a different URL, you aren’t getting the full PageRank benefit of those backlinks. The link juice is watered down and divvied up between the two different URLs instead of being concentrated into one of them.

While Jeff only focuses on the reasons related to SEO, there are many other reasons to make your URL’s “look-and-feel” a hire priority.  One that is often touted as a wonderful reason to use a URL Rewriter is to produce pretty looking URL’s, and even though this one of many reasons to use a rewriter, it is really a small part of why you want to have a URL Rewriter in your arsenal as a web developer.  Other reasons include forcing your domain to a constant www vs non-www address, having helper URL’s such as http://www.microsoft.com/sql that redirect to their actual location, and many others.

routing_engine

However, since Microsoft released the System.Web.Routing framework the benefits for using a URL Rewriter have been blurred, because the routing framework gives developers more of an ability to control the URL and thus create prettier URL’s than have traditionally been possible.  Because of this overlap of efforts, in the router and rewriter, in making a more readable URL a misunderstand has been created about the functions and benefits that each provide to the modern web developer.

The first thing to understanding the difference between routes and a rewriter. Phil Haack explains on his blog the reasons routes were not designed to be changeable without a recompile:

This is partly by design as routes are generally considered application code, and should have associated unit tests to verify that the routes are correct. A misconfigured route could seriously tank your application.

In other words the route which is compiled “application code” is like a road, and like the properties of a road it provides a way to get between the starting point and the destination, or in the case of the web the client browser requesting a URL as the start point and your action method as the destination.  If this road could be changed with out much thought, it would be possible to create a circumstance where your destination is no longer accessible by the road. The rewriter on the other hand can be looked at as the rules of the road used to detour traffic, govern the speed, give direction, and really just provide flexibility on top of the rigid start and end points of the road.

When I try to explain this to fellow developers I often have a conversation that goes something like this:


[ME] Why are you not using a rewriter in your ASP.NET MVC application to give you better control over your URL routes.  So that you provide a consistent domain, helper URL’s, and more flexibility to the running of your web application?
[THEM] I don’t need a rewriter, I use ASP.NET MVC for creating pretty URL’s and Routing rocks.
[ME] Sigh, I never said anything about pretty URL’s. The benefits of a URL Rewriter go way beyond making your URL pretty.
[THEM] I don’t see how. The interweb always talks about pretty URL’s and rewriters.
[ME] Well, Routing is like namespaces for your actions they just provide a web accessible name to get directly to your action method, they don’t act as a rule engine on what types of requests to let through, what type to redirect, and where the request should go.  That is why you need a URL Rewriter in addition to Routing.  Thing of a route as a road, and the rewriter the rules you use to drive on that road.
[THEM] I like driving fast in my Prius.
[ME] Double Sign. Lets focus here for a minute.  Lets get back on topic.
[THEM] Yeah but so what I don’t need any of that mumbo jumbo, I just want pretty URL’s because that is all that people talk about on the interweb, and that is how you get to #1 on Google.
[ME] Fine Good Luck with your PageRank, come back to me in a year when you are still at the exact same rank in Google and ready to listen.


It has gotten really to the point where I start picking the people I want to have this conversation with based on if they are actually willing to listen and understand enough of the basics of SEO and HTTP so that my conversation is not lost on them.

If you have gotten this far in to my rant on the differences of routing and rewriters, you are probably somebody who generally cares and already understands the difference or wants to know more.  If you are that person, I would love to talk to you about what kind of enhancements to my companies URL Rewriter that would make your life easier as a web developer.  As I start to line up the features for the 4.0 release.

Tags: , , ,

Posted in Programming, Rant | kick it on DotNetKicks.com | Bookmark | View blog reactions | Comments Off

June 7th, 2009

Managed Fusion URL Rewriter & Reverse Proxy – Release 3.0

I am happy to announce the 3.0 release of the Managed Fusion URL Rewriter & Reverse Proxy. Since my previous release in February I have been working hard on a significant rewrite of the core, that to be honest really needed refactoring if I hoped to extend the rewriter is some interesting ways in the future.

Download: Binary Release
View: Source Code
Discuss: Forum
Issues: Report

Release Notes

If you would like to find out more about the past releases please visit us at http://www.managedfusion.com/products/url-rewriter/release-notes.aspx

Version 3.0

  • Breaking Change Configuration in the web.config has been reorganized.
  • Major rewrite to the URL Rewriter to provide better performance and more reliable logging.
  • Major update to the proxy handler, it is much faster, and provides an exact duplication of headers from the proxied server.
  • Fixed many issues with the chunked encoding, so you are now able to proxy web based services, such as SVN.
  • Full rewrite of the rule, condition, and flag handling system to provide better performance and more flexibility for developers.
  • More extensibility points have been created for developers interested in creating their own handlers for rules, conditions, and flags.
  • More extensive testing of internal mechanics of the rewriter.
  • Added thread safety to the Apache rule set refresh.
  • Added initial support for Microsoft UrlRewriter IIS 7 module, this will provided a starting point for extension of the Microsoft configuration to support proxying and other more advanced Apache features.

Featured at PDC 2008

Tags: , ,

Posted in News | kick it on DotNetKicks.com | Bookmark | View blog reactions | 5 Comments »

February 1st, 2009

Managed Fusion URL Rewriter & Reverse Proxy Release 2.5

Download: Binary Release
Download: Source Code

Release Notes

If you would like to find out more about the past releases please visit us at http://www.managedfusion.com/products/url-rewriter/release-notes.aspx

Version 2.5

    • Major update to the proxy handler, it is not much faster, and provides an exact duplication of headers from the proxied server.
    • Added full support for $N and %N support in conditions and rules now.
    • Added contexts for condition, rule, and ruleset to make transfer of common data easier for implementations of the API.
    • Added split between async and sync proxy handler, this can now be controlled through the web.config using useAsyncProxy.
    • Fixed issue with transfer-encoding: chuncked

      Tags: ,

      Posted in News | kick it on DotNetKicks.com | Bookmark | View blog reactions | 1 Comment »