Removed unnecessary exceptions from method signatures and try-catch blocks.
Made uri a URI object instead of String, parsed query string and added unit tests for it.
Made the ability to use absolute urls in start line an option in server config.
Refactored code.