* Primitive rate limits: enforce maximum actions per time period
* to put a brake on flooding.
*
+ * The method generates both a generic profiling point and a per action one
+ * (suffix being "-$action".
+ *
* @note When using a shared cache like memcached, IP-address
* last-hit counters will be shared across wikis.
*
global $wgMemc;
wfProfileIn( __METHOD__ );
+ wfProfileIn( __METHOD__ . '-' . $action );
$limits = $wgRateLimits[$action];
$keys = array();
}
}
+ wfProfileOut( __METHOD__ . '-' . $action );
wfProfileOut( __METHOD__ );
return $triggered;
}