refactor application for URL namespaces