Produces a canonical representation of a URL used as the deduplication key
(unique_key) of a request. Normalisation lower-cases the scheme and host,
removes a trailing slash from the path, drops default ports and sorts the
query parameters so that semantically identical URLs collapse to the same
key.