setting to turn off expensive queries
This commit is contained in:
parent
b44bb472eb
commit
ddf166e144
|
@ -852,3 +852,10 @@ path: Path to the plugin files. defaults to site/path + '/plugins/'. Expects tha
|
||||||
each plugin will have a subdirectory at plugins/NameOfPlugin. Change this
|
each plugin will have a subdirectory at plugins/NameOfPlugin. Change this
|
||||||
if you're using a CDN.
|
if you're using a CDN.
|
||||||
sslpath: Path to use on the SSL server. Same as plugins/path.
|
sslpath: Path to use on the SSL server. Same as plugins/path.
|
||||||
|
|
||||||
|
performance
|
||||||
|
-----------
|
||||||
|
|
||||||
|
high: if you need high performance, or if you're seeing bad
|
||||||
|
performance, set this to true. It will turn off some high-intensity code from
|
||||||
|
the site.
|
||||||
|
|
|
@ -211,12 +211,13 @@ class AllAction extends ProfileAction
|
||||||
$ibs->show();
|
$ibs->show();
|
||||||
}
|
}
|
||||||
// XXX: make this a little more convenient
|
// XXX: make this a little more convenient
|
||||||
if (common_config('site', 'private')) {
|
|
||||||
|
if (!common_config('performance', 'high')) {
|
||||||
$pop = new PopularNoticeSection($this);
|
$pop = new PopularNoticeSection($this);
|
||||||
$pop->show();
|
$pop->show();
|
||||||
|
$pop = new InboxTagCloudSection($this, $this->user);
|
||||||
|
$pop->show();
|
||||||
}
|
}
|
||||||
// $pop = new InboxTagCloudSection($this, $this->user);
|
|
||||||
// $pop->show();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -173,7 +173,9 @@ class AttachmentAction extends Action
|
||||||
function showSections() {
|
function showSections() {
|
||||||
$ns = new AttachmentNoticeSection($this);
|
$ns = new AttachmentNoticeSection($this);
|
||||||
$ns->show();
|
$ns->show();
|
||||||
$atcs = new AttachmentTagCloudSection($this);
|
if (!common_config('performance', 'high')) {
|
||||||
$atcs->show();
|
$atcs = new AttachmentTagCloudSection($this);
|
||||||
|
$atcs->show();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -245,7 +245,7 @@ class PublicAction extends Action
|
||||||
|
|
||||||
$pop = new PopularNoticeSection($this);
|
$pop = new PopularNoticeSection($this);
|
||||||
$pop->show();
|
$pop->show();
|
||||||
if (common_config('site', 'private')) {
|
if (common_config('performance', 'high')) {
|
||||||
$cloud = new PublicTagCloudSection($this);
|
$cloud = new PublicTagCloudSection($this);
|
||||||
$cloud->show();
|
$cloud->show();
|
||||||
}
|
}
|
||||||
|
|
|
@ -285,8 +285,10 @@ class ShowstreamAction extends ProfileAction
|
||||||
function showSections()
|
function showSections()
|
||||||
{
|
{
|
||||||
parent::showSections();
|
parent::showSections();
|
||||||
$cloud = new PersonalTagCloudSection($this, $this->user);
|
if (!common_config('performance', 'high')) {
|
||||||
$cloud->show();
|
$cloud = new PersonalTagCloudSection($this, $this->user);
|
||||||
|
$cloud->show();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function noticeFormOptions()
|
function noticeFormOptions()
|
||||||
|
|
|
@ -274,10 +274,12 @@ class Router
|
||||||
array('action' => 'userbyid'),
|
array('action' => 'userbyid'),
|
||||||
array('id' => '[0-9]+'));
|
array('id' => '[0-9]+'));
|
||||||
|
|
||||||
$m->connect('tags/', array('action' => 'publictagcloud'));
|
if (!common_config('performance', 'high')) {
|
||||||
$m->connect('tag/', array('action' => 'publictagcloud'));
|
$m->connect('tags/', array('action' => 'publictagcloud'));
|
||||||
$m->connect('tags', array('action' => 'publictagcloud'));
|
$m->connect('tag/', array('action' => 'publictagcloud'));
|
||||||
$m->connect('tag', array('action' => 'publictagcloud'));
|
$m->connect('tags', array('action' => 'publictagcloud'));
|
||||||
|
$m->connect('tag', array('action' => 'publictagcloud'));
|
||||||
|
}
|
||||||
$m->connect('tag/:tag/rss',
|
$m->connect('tag/:tag/rss',
|
||||||
array('action' => 'tagrss'),
|
array('action' => 'tagrss'),
|
||||||
array('tag' => self::REGEX_TAG));
|
array('tag' => self::REGEX_TAG));
|
||||||
|
@ -898,7 +900,9 @@ class Router
|
||||||
|
|
||||||
// people tags
|
// people tags
|
||||||
|
|
||||||
$m->connect('peopletags', array('action' => 'publicpeopletagcloud'));
|
if (!common_config('performance', 'high')) {
|
||||||
|
$m->connect('peopletags', array('action' => 'publicpeopletagcloud'));
|
||||||
|
}
|
||||||
|
|
||||||
$m->connect('peopletag/:tag', array('action' => 'peopletag',
|
$m->connect('peopletag/:tag', array('action' => 'peopletag',
|
||||||
'tag' => self::REGEX_TAG));
|
'tag' => self::REGEX_TAG));
|
||||||
|
|
Loading…
Reference in New Issue
Block a user