Manual:$wgMWLoggerDefaultSpi/pl

From Linux Web Expert

<translate> Debug</translate>: $wgMWLoggerDefaultSpi
Default service provider for creating MWLogger instances.
<translate> Introduced in version:</translate>1.25.0 (Gerrit change 119940; git #9b358016)
<translate> Removed in version:</translate><translate> still in use</translate>
<translate> Allowed values:</translate><translate> Unspecified</translate>
<translate> Default value:</translate>patrz poniżej

Szczegóły

The value should be an array suitable for use with ObjectFactory::getObjectFromSpec(). The created object is expected to implement the MWLoggerSpi interface. Zobacz ObjectFactory, aby uzyskać więcej szczegółów.

NullSpi creates MWLogger instances that will discard all logging events.

$wgMWLoggerDefaultSpi = [ 'class' => '\\MediaWiki\\Logger\\NullSpi', ];

LegacySpi (default) creates LegacyLogger instances which mimic the historic implementation of MediaWiki's wfErrorLog logging implementation.

$wgMWLoggerDefaultSpi = [ 'class' => '\\MediaWiki\\Logger\\LegacySpi', ];

MWLoggerMonologSpi creates loggers implemented by Monolog.

See Manual:MWLoggerMonologSpi for configuration settings.

$wgMWLoggerDefaultSpi = [ 'class' => '\\MediaWiki\\Logger\\MonologSpi', 'args' => ... ];


Default value

<td class="mw-version-versionbox" title="<translate nowrap> The latest stable version is <tvar name=1>1.41</tvar></translate>">
<translate> ≥</translate> 1.39
<translate> MediaWiki version:</translate>
$wgMWLoggerDefaultSpi = [ 'class' => 'MediaWiki\\Logger\\LegacySpi', ]
<td class="mw-version-versionbox" title="<translate nowrap> MediaWiki <tvar name=1>1.38</tvar> is unsupported version</translate>">
1.31 – 1.38
<translate> MediaWiki versions:</translate>
$wgMWLoggerDefaultSpi = [
	'class' => \MediaWiki\Logger\LegacySpi::class,
]
<td class="mw-version-versionbox" title="<translate nowrap> MediaWiki <tvar name=1>1.30</tvar> is unsupported version</translate>">
1.25 – 1.30
<translate> MediaWiki versions:</translate>
$wgMWLoggerDefaultSpi = array(
	'class' => '\\MediaWiki\\Logger\\LegacySpi',
)

Zobacz też