You are here

public static function DrupalMemcachedUtils::log in Memcache Storage 8

Register shutdown callable to log a message. We need to do this on shutdown because in the initial phase loggers might be not available.

Parameters

$level: \Psr\Log\LogLevel constant

$message: A message which should be logged.

$context: An array with additional information about the event - uid, link, etc.

1 call to DrupalMemcachedUtils::log()
DrupalMemcachedBase::addServers in src/DrupalMemcachedBase.php

File

src/DrupalMemcachedUtils.php, line 73

Class

DrupalMemcachedUtils

Namespace

Drupal\memcache_storage

Code

public static function log($level, $message, array $context = []) {
  \register_shutdown_function(array(
    'Drupal\\memcache_storage\\DrupalMemcachedUtils',
    'logShutdown',
  ), $level, $message, $context);
}