adding newrelic support
decode url first
a little cleanup