/**
* Handles a HTTP request
*
* @return void
*/
public function handleRequest()
{
// Create the request very early so the ResourceManagement has a chance to grab it:
$request = Request::createFromEnvironment();
$response = new Response();
$this->componentContext = new ComponentContext($request, $response);
$this->boot();
$this->resolveDependencies();
$this->addPoweredByHeader($response);
if (isset($this->settings['http']['baseUri'])) {
$request->setBaseUri(new Uri($this->settings['http']['baseUri']));
}
$this->baseComponentChain->handle($this->componentContext);
$response = $this->baseComponentChain->getResponse();
$response->send();
$this->bootstrap->shutdown(Bootstrap::RUNLEVEL_RUNTIME);
$this->exit->__invoke();
}