You are here

private function GuzzleConnectionDebug::logErrorDueToFailure in Elasticsearch Connector 7

Same name and namespace in other branches
  1. 7.5 modules/elasticsearch_connector_devel/includes/GuzzleConnectionDebugging.inc \Elasticsearch\Connections\GuzzleConnectionDebug::logErrorDueToFailure()
  2. 7.2 modules/elasticsearch_connector_devel/includes/GuzzleConnectionDebugging.inc \Elasticsearch\Connections\GuzzleConnectionDebug::logErrorDueToFailure()

Parameters

Request $request:

\Exception $exception:

string $body:

2 calls to GuzzleConnectionDebug::logErrorDueToFailure()
GuzzleConnectionDebug::process4xxError in modules/elasticsearch_connector_devel/includes/GuzzleConnectionDebugging.inc
GuzzleConnectionDebug::process5xxError in modules/elasticsearch_connector_devel/includes/GuzzleConnectionDebugging.inc

File

modules/elasticsearch_connector_devel/includes/GuzzleConnectionDebugging.inc, line 278

Class

GuzzleConnectionDebug

Namespace

Elasticsearch\Connections

Code

private function logErrorDueToFailure(Request $request, \Exception $exception, $body) {
  $response = $request
    ->getResponse();
  $headers = $request
    ->getHeaders()
    ->getAll();
  $this
    ->logRequestFail($request
    ->getMethod(), $request
    ->getUrl(), $response
    ->getInfo('total_time'), $headers, $response
    ->getStatusCode(), $body, $exception
    ->getMessage());
}