Ensure a query string always appears in the same order so it can be cached

Symfony has a normalizer that could be useful for this:

https://github.com/symfony/symfony/blob/2.0/src/Symfony/Component/HttpFoundation/Request.php#method_getQueryString