Parse '<protocol>://<host>:<port><path>' into an object.
Port and path are optional.
solve('https://example.com:8080/api') → { protocol: 'https', host: 'example.com', port: 8080, path: '/api' }.
If no port: port: null. If no path: path: ''.
Sample tests