Pulled out full url parsing into common method.
Pulled out full url parsing into common method.

Also fixed /metadata and /metadata-server to serve the full url instead of the relpath.

rhass/opscode-omnitruck,juliandunn/opscode-omnitruck,chef/omnitruck,juliandunn/opscode-omnitruck,glennmatthews/opscode-omnitruck,juliandunn/opscode-omnitruck,chef/opscode-omnitruck,glennmatthews/opscode-omnitruck,glennmatthews/opscode-omnitruck,rhass/opscode-omnitruck,chef/omnitruck,chef/opscode-omnitruck,rhass/opscode-omnitruck,chef/omnitruck,chef/opscode-omnitruck