Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
Public Member Functions
HttpPlugin Class Reference

Public Member Functions

 __construct (Config $config, NewRelicWrapper $newRelicWrapper)
 
 beforeCatchException (Http $subject, Bootstrap $bootstrap, \Exception $exception)
 

Detailed Description

Definition at line 13 of file HttpPlugin.php.

Constructor & Destructor Documentation

◆ __construct()

__construct ( Config  $config,
NewRelicWrapper  $newRelicWrapper 
)
Parameters
Config$config
NewRelicWrapper$newRelicWrapper

Definition at line 29 of file HttpPlugin.php.

32  {
33  $this->config = $config;
34  $this->newRelicWrapper = $newRelicWrapper;
35  }
$config
Definition: fraud_order.php:17

Member Function Documentation

◆ beforeCatchException()

beforeCatchException ( Http  $subject,
Bootstrap  $bootstrap,
\Exception  $exception 
)

Report exception to New Relic

Parameters
Http$subject
Bootstrap$bootstrap
\Exception$exception
Returns
void

@SuppressWarnings(PHPMD.UnusedFormalParameter)

Definition at line 47 of file HttpPlugin.php.

48  {
49  if ($this->config->isNewRelicEnabled()) {
50  $this->newRelicWrapper->reportError($exception);
51  }
52  }

The documentation for this class was generated from the following file: