mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Math
synced 2024-11-23 23:25:02 +00:00
Logging: adjust the log entry levels
Most info-level log entries are actually debug messages, which should not end up in the production log by default, so adjust them. Only the Mathoid-powered TeX check fail has been promoted to info so that we can quickly identify such requests from pages. Bug: T121445 Change-Id: I3736c59f6425d675befea9438182ee1cdebe5fc5
This commit is contained in:
parent
c3ebc54994
commit
a3072e273b
|
@ -202,7 +202,7 @@ class MathHooks {
|
|||
}
|
||||
|
||||
if ( $renderer->render() ) {
|
||||
LoggerFactory::getInstance( 'Math' )->info( "Rendering successful. Writing output" );
|
||||
LoggerFactory::getInstance( 'Math' )->debug( "Rendering successful. Writing output" );
|
||||
$renderedMath = $renderer->getHtmlOutput();
|
||||
} else {
|
||||
LoggerFactory::getInstance( 'Math' )->warning(
|
||||
|
|
|
@ -165,7 +165,7 @@ abstract class MathRenderer {
|
|||
default:
|
||||
$renderer = new MathMathML( $tex, $params );
|
||||
}
|
||||
LoggerFactory::getInstance( 'Math' )->info( 'Start rendering $' . $renderer->tex .
|
||||
LoggerFactory::getInstance( 'Math' )->debug( 'Start rendering $' . $renderer->tex .
|
||||
'$ in mode ' . $mode );
|
||||
return $renderer;
|
||||
}
|
||||
|
@ -322,7 +322,7 @@ abstract class MathRenderer {
|
|||
# Now save it back to the DB:
|
||||
if ( !wfReadOnly() ) {
|
||||
$dbw = $dbw ?: wfGetDB( DB_MASTER );
|
||||
LoggerFactory::getInstance( 'Math' )->info( 'Store entry for $' . $this->tex .
|
||||
LoggerFactory::getInstance( 'Math' )->debug( 'Store entry for $' . $this->tex .
|
||||
'$ in database (hash:' . $this->getMd5() . ')' );
|
||||
$outArray = $this->dbOutArray();
|
||||
$method = __METHOD__;
|
||||
|
|
|
@ -116,7 +116,7 @@ class MathRestbaseInterface {
|
|||
return true;
|
||||
} else {
|
||||
$res = $response['body'];
|
||||
$this->log()->debug( 'Tex check failed:', array(
|
||||
$this->log()->info( 'Tex check failed:', array(
|
||||
'post' => $post,
|
||||
'error' => $response['error'],
|
||||
'url' => $request['url']
|
||||
|
|
|
@ -46,7 +46,7 @@ class MathTexvc extends MathRenderer {
|
|||
$out['math_html'] = $this->html;
|
||||
$out['math_mathml'] = utf8_encode( $this->getMathml() );
|
||||
$out['math_inputhash'] = $this->getInputHash();
|
||||
LoggerFactory::getInstance( 'Math' )->info( 'Store Hashpath of image' .
|
||||
LoggerFactory::getInstance( 'Math' )->debug( 'Store Hashpath of image' .
|
||||
bin2hex( $outmd5_sql ) );
|
||||
return $out;
|
||||
}
|
||||
|
@ -68,7 +68,7 @@ class MathTexvc extends MathRenderer {
|
|||
$xhash = unpack( 'H32md5',
|
||||
$dbr->decodeBlob( $rpage->math_outputhash ) . " " );
|
||||
$this->hash = $xhash['md5'];
|
||||
LoggerFactory::getInstance( 'Math' )->info( 'Hashpath of PNG-File:' .
|
||||
LoggerFactory::getInstance( 'Math' )->debug( 'Hashpath of PNG-File:' .
|
||||
bin2hex( $this->hash ) );
|
||||
$this->conservativeness = $rpage->math_html_conservativeness;
|
||||
$this->html = $rpage->math_html;
|
||||
|
|
Loading…
Reference in a new issue