public function forwardUrl($url)
    {
        $uri = new Uri($url);
        $query = $uri->getQuery();
        $queryParams = [];
        if (strlen($query) > 0) {
            parse_str($query, $queryParams);
        }

        switch ($this->getPsrRequest()->getMethod()) {
            case 'GET' :
                $params = $this->getPsrRequest()->getQueryParams();
                break;
            case 'POST' :
                $params = $this->getPsrRequest()->getParsedBody();
                break;
            default:
                $params = [];
        }
        $request = $this->getPsrRequest()
            ->withUri($uri)
            ->withQueryParams((array) $queryParams);

        //resolve the given URL for routing
        $resolver = new Resolver($request);
        $this->propagate($resolver);

        //update the context to the new route
        $context = \Context::getInstance();
        $context->setExtensionName($resolver->getExtensionId());
        $context->setModuleName($resolver->getControllerShortName());
        $context->setActionName($resolver->getMethodName());

        $context->getRequest()->addParameters($queryParams);

        $request = $request
            ->withAttribute('extension', $resolver->getExtensionId())
            ->withAttribute('controller', $resolver->getControllerShortName())
            ->withAttribute('method', $resolver->getMethodName());

        //execute the new action
        $enforcer = new ActionEnforcer(
            $resolver->getExtensionId(),
            $resolver->getControllerClass(),
            $resolver->getMethodName(),
            $params
        );
        $this->propagate($enforcer);

        $enforcer(
            $request,
            $this->response->withHeader(
                'X-Tao-Forward',
                $resolver->getExtensionId() . '/' .  $resolver->getControllerShortName() . '/' . $resolver->getMethodName()
            )
        );

        throw new InterruptedActionException(
            'Interrupted action after a forwardUrl',
            $context->getModuleName(),
            $context->getActionName()
        );
    }