Commit eb66a027 authored by Tino Goratsch's avatar Tino Goratsch

brought the HTTP cache in place

parent b1a4d333
......@@ -58,6 +58,14 @@ abstract class AbstractBootstrap implements BootstrapInterface
return $this->container;
}
/**
* @return ApplicationPath
*/
public function getAppPath()
{
return $this->appPath;
}
/**
* Checks, whether the database configuration file exists
*
......
......@@ -91,7 +91,7 @@ class Bootstrap extends AbstractBootstrap
Utf8\Bootup::filterRequestUri(); // Redirects to an UTF-8 encoded URL if it's not already the case
Utf8\Bootup::filterRequestInputs(); // Normalizes HTTP inputs to UTF-8 NFC
$file = $this->appPath->getCacheDir() . 'sql/container.php';
$file = $this->appPath->getCacheDir() . 'container.php';
$this->dumpContainer($symfonySymfonyRequest, $file);
......
......@@ -23,6 +23,15 @@ if (!$kernel->startupChecks()) {
exit;
}
$kernel
->handle($request)
->send();
$cacheStore = new \Symfony\Component\HttpKernel\HttpCache\Store(
$kernel->getAppPath()->getCacheDir() . 'http/'
);
$httpCache = new \Symfony\Component\HttpKernel\HttpCache\HttpCache(
$kernel,
$cacheStore,
new \Symfony\Component\HttpKernel\HttpCache\Esi(),
['debug' => $appMode === \ACP3\Core\Environment\ApplicationMode::DEVELOPMENT]
);
$httpCache->handle($request)->send();
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment