if ($referer = $request->headers->get('referer')) {
$message .= sprintf(' (from "%s")', $referer);
}
throw new NotFoundHttpException($message, $e);
} catch (MethodNotAllowedException $e) {
$message = sprintf('No route found for "%s %s": Method Not Allowed (Allow: %s)', $request->getMethod(), $request->getUriForPath($request->getPathInfo()), implode(', ', $e->getAllowedMethods()));
throw new MethodNotAllowedHttpException($e->getAllowedMethods(), $message, $e);
}
$request = $event->getRequest();
// This call is required in all cases, because the default router needs our webspace information
// Would be nice to also only call this if the _requestAnalyzer attribute is set, but it's set on the next line
$this->requestAnalyzer->analyze($request);
$this->baseRouteListener->onKernelRequest($event);
if (false !== $request->attributes->getBoolean(static::REQUEST_ANALYZER, true)) {
$this->requestAnalyzer->validate($request);
}
}
$this->priority = $dispatcher->getListenerPriority($eventName, $this->listener);
$e = $this->stopwatch->start($this->name, 'event_listener');
try {
($this->optimizedListener ?? $this->listener)($event, $eventName, $dispatcher);
} finally {
if ($e->isStarted()) {
$e->stop();
}
}
foreach ($listeners as $listener) {
if ($stoppable && $event->isPropagationStopped()) {
break;
}
$listener($event, $eventName, $this);
}
}
/**
* Sorts the internal list of listeners for the given event by priority.
} else {
$listeners = $this->getListeners($eventName);
}
if ($listeners) {
$this->callListeners($listeners, $eventName, $event);
}
return $event;
}
try {
$this->beforeDispatch($eventName, $event);
try {
$e = $this->stopwatch->start($eventName, 'section');
try {
$this->dispatcher->dispatch($event, $eventName);
} finally {
if ($e->isStarted()) {
$e->stop();
}
}
*/
private function handleRaw(Request $request, int $type = self::MAIN_REQUEST): Response
{
// request
$event = new RequestEvent($this, $request, $type);
$this->dispatcher->dispatch($event, KernelEvents::REQUEST);
if ($event->hasResponse()) {
return $this->filterResponse($event->getResponse(), $request, $type);
}
{
$request->headers->set('X-Php-Ob-Level', (string) ob_get_level());
$this->requestStack->push($request);
try {
return $this->handleRaw($request, $type);
} catch (\Exception $e) {
if ($e instanceof RequestExceptionInterface) {
$e = new BadRequestHttpException($e->getMessage(), $e);
}
if (false === $catch) {
$this->boot();
++$this->requestStackSize;
$this->resetServices = true;
try {
return $this->getHttpKernel()->handle($request, $type, $catch);
} finally {
--$this->requestStackSize;
}
}
// When using the HttpCache, you need to call the method in your front controller
// instead of relying on the configuration parameter
// https://symfony.com/doc/3.4/reference/configuration/framework.html#http-method-override
Request::enableHttpMethodParameterOverride();
$request = Request::createFromGlobals();
$response = $kernel->handle($request);
$response->send();
$kernel->terminate($request, $response);
$info = $request
? "this request\n$request"
: "url '$pathinfo'";
throw $methodNotAllowed ?: new ResourceNotFoundException("None of the routers in the chain matched $info");
}
/**
* {@inheritdoc}
*
*
* Loops through all routes and tries to match the passed request.
*/
public function matchRequest(Request $request)
{
return $this->doMatch($request->getPathInfo(), $request);
}
/**
* Loops through all routers and tries to match the passed request or url.
*
// add attributes based on the request (routing)
try {
// matching a request is more powerful than matching a URL path + context, so try that first
if ($this->matcher instanceof RequestMatcherInterface) {
$parameters = $this->matcher->matchRequest($request);
} else {
$parameters = $this->matcher->match($request->getPathInfo());
}
if (null !== $this->logger) {
$request = $event->getRequest();
// This call is required in all cases, because the default router needs our webspace information
// Would be nice to also only call this if the _requestAnalyzer attribute is set, but it's set on the next line
$this->requestAnalyzer->analyze($request);
$this->baseRouteListener->onKernelRequest($event);
if (false !== $request->attributes->getBoolean(static::REQUEST_ANALYZER, true)) {
$this->requestAnalyzer->validate($request);
}
}
$this->priority = $dispatcher->getListenerPriority($eventName, $this->listener);
$e = $this->stopwatch->start($this->name, 'event_listener');
try {
($this->optimizedListener ?? $this->listener)($event, $eventName, $dispatcher);
} finally {
if ($e->isStarted()) {
$e->stop();
}
}
foreach ($listeners as $listener) {
if ($stoppable && $event->isPropagationStopped()) {
break;
}
$listener($event, $eventName, $this);
}
}
/**
* Sorts the internal list of listeners for the given event by priority.
} else {
$listeners = $this->getListeners($eventName);
}
if ($listeners) {
$this->callListeners($listeners, $eventName, $event);
}
return $event;
}
try {
$this->beforeDispatch($eventName, $event);
try {
$e = $this->stopwatch->start($eventName, 'section');
try {
$this->dispatcher->dispatch($event, $eventName);
} finally {
if ($e->isStarted()) {
$e->stop();
}
}
*/
private function handleRaw(Request $request, int $type = self::MAIN_REQUEST): Response
{
// request
$event = new RequestEvent($this, $request, $type);
$this->dispatcher->dispatch($event, KernelEvents::REQUEST);
if ($event->hasResponse()) {
return $this->filterResponse($event->getResponse(), $request, $type);
}
{
$request->headers->set('X-Php-Ob-Level', (string) ob_get_level());
$this->requestStack->push($request);
try {
return $this->handleRaw($request, $type);
} catch (\Exception $e) {
if ($e instanceof RequestExceptionInterface) {
$e = new BadRequestHttpException($e->getMessage(), $e);
}
if (false === $catch) {
$this->boot();
++$this->requestStackSize;
$this->resetServices = true;
try {
return $this->getHttpKernel()->handle($request, $type, $catch);
} finally {
--$this->requestStackSize;
}
}
// When using the HttpCache, you need to call the method in your front controller
// instead of relying on the configuration parameter
// https://symfony.com/doc/3.4/reference/configuration/framework.html#http-method-override
Request::enableHttpMethodParameterOverride();
$request = Request::createFromGlobals();
$response = $kernel->handle($request);
$response->send();
$kernel->terminate($request, $response);
No log messages
[2/2]
NotFoundHttpException
|
---|
Symfony\Component\HttpKernel\Exception\NotFoundHttpException: No route found for "GET https://www.juwelier-becker.com/cn/%E9%92%9F%E8%A1%A8/chronoswiss/" (from "http://www.juwelier-becker.com/cn/%E9%92%9F%E8%A1%A8/chronoswiss/") at vendor/symfony/http-kernel/EventListener/RouterListener.php:135 at Symfony\Component\HttpKernel\EventListener\RouterListener->onKernelRequest() (vendor/sulu/sulu/src/Sulu/Bundle/WebsiteBundle/EventListener/RouterListener.php:57) at Sulu\Bundle\WebsiteBundle\EventListener\RouterListener->onKernelRequest() (vendor/symfony/event-dispatcher/Debug/WrappedListener.php:118) at Symfony\Component\EventDispatcher\Debug\WrappedListener->__invoke() (vendor/symfony/event-dispatcher/EventDispatcher.php:230) at Symfony\Component\EventDispatcher\EventDispatcher->callListeners() (vendor/symfony/event-dispatcher/EventDispatcher.php:59) at Symfony\Component\EventDispatcher\EventDispatcher->dispatch() (vendor/symfony/event-dispatcher/Debug/TraceableEventDispatcher.php:154) at Symfony\Component\EventDispatcher\Debug\TraceableEventDispatcher->dispatch() (vendor/symfony/http-kernel/HttpKernel.php:139) at Symfony\Component\HttpKernel\HttpKernel->handleRaw() (vendor/symfony/http-kernel/HttpKernel.php:75) at Symfony\Component\HttpKernel\HttpKernel->handle() (vendor/symfony/http-kernel/Kernel.php:202) at Symfony\Component\HttpKernel\Kernel->handle() (public/index.php:66) |
[1/2]
ResourceNotFoundException
|
---|
Symfony\Component\Routing\Exception\ResourceNotFoundException: None of the routers in the chain matched this request GET /cn/%E9%92%9F%E8%A1%A8/chronoswiss/ HTTP/1.1 Accept: */* Accept-Encoding: gzip Host: www.juwelier-becker.com Referer: http://www.juwelier-becker.com/cn/%E9%92%9F%E8%A1%A8/chronoswiss/ Surrogate-Capability: abc=ESI/1.0 User-Agent: claudebot X-Forwarded-For: 44.197.191.240, 10.0.1.1 X-Forwarded-Host: www.juwelier-becker.com X-Forwarded-Port: 443 X-Forwarded-Proto: https X-Forwarded-Server: 1243805376aa X-Php-Ob-Level: 1 X-Real-Ip: 44.197.191.240 X-Varnish: 10141947 at vendor/symfony-cmf/routing/src/ChainRouter.php:210 at Symfony\Cmf\Component\Routing\ChainRouter->doMatch() (vendor/symfony-cmf/routing/src/ChainRouter.php:158) at Symfony\Cmf\Component\Routing\ChainRouter->matchRequest() (vendor/symfony/http-kernel/EventListener/RouterListener.php:111) at Symfony\Component\HttpKernel\EventListener\RouterListener->onKernelRequest() (vendor/sulu/sulu/src/Sulu/Bundle/WebsiteBundle/EventListener/RouterListener.php:57) at Sulu\Bundle\WebsiteBundle\EventListener\RouterListener->onKernelRequest() (vendor/symfony/event-dispatcher/Debug/WrappedListener.php:118) at Symfony\Component\EventDispatcher\Debug\WrappedListener->__invoke() (vendor/symfony/event-dispatcher/EventDispatcher.php:230) at Symfony\Component\EventDispatcher\EventDispatcher->callListeners() (vendor/symfony/event-dispatcher/EventDispatcher.php:59) at Symfony\Component\EventDispatcher\EventDispatcher->dispatch() (vendor/symfony/event-dispatcher/Debug/TraceableEventDispatcher.php:154) at Symfony\Component\EventDispatcher\Debug\TraceableEventDispatcher->dispatch() (vendor/symfony/http-kernel/HttpKernel.php:139) at Symfony\Component\HttpKernel\HttpKernel->handleRaw() (vendor/symfony/http-kernel/HttpKernel.php:75) at Symfony\Component\HttpKernel\HttpKernel->handle() (vendor/symfony/http-kernel/Kernel.php:202) at Symfony\Component\HttpKernel\Kernel->handle() (public/index.php:66) |