Item1383: Plugin Topic PREFERENCES still used in core plugins
Priority: Urgent
Current State: Closed
Released In: 1.1.0
Target Release: minor
Applies To: Engine
Component:
Branches:
which means that every time we view a topic, we read many more files than needed.
for a
http://server/view/Main/WebHome?skin=plain
I get the following files read
[Sat Mar 28 12:35:15 2009].../data/System/DefaultPreferences.txt)
[Sat Mar 28 12:35:15 2009].../data/System/SpreadSheetPlugin.txt) -- Main.CrawfordCurrie - 15 Apr 2009
[Sat Mar 28 12:35:15 2009].../data/System/TinyMCEPlugin.txt) -- Main.CrawfordCurrie - 03 Apr 2009
[Sat Mar 28 12:35:15 2009].../data/System/InterwikiPlugin.txt) -- Main.CrawfordCurrie - 15 Apr 2009
[Sat Mar 28 12:35:15 2009].../data/System/SmiliesPlugin.txt) -- Main.CrawfordCurrie - 15 Apr 2009
[Sat Mar 28 12:35:15 2009].../data/System/CalendarPlugin.txt)
[Sat Mar 28 12:35:15 2009].../data/System/EditTablePlugin.txt) -- Main.CrawfordCurrie - 16 Apr 2009
[Sat Mar 28 12:35:15 2009].../data/System/FormPlugin.txt)
[Sat Mar 28 12:35:15 2009].../data/System/HolidaylistPlugin.txt)
[Sat Mar 28 12:35:15 2009].../data/System/PreferencesPlugin.txt) -- Main.CrawfordCurrie - 15 Apr 2009
[Sat Mar 28 12:35:15 2009].../data/System/RenderListPlugin.txt) -- Main.CrawfordCurrie - 15 Apr 2009
[Sat Mar 28 12:35:15 2009].../data/System/SlideShowPlugin.txt) -- Main.CrawfordCurrie - 16 Apr 2009
[Sat Mar 28 12:35:15 2009].../data/System/TablePlugin.txt) -- Main.CrawfordCurrie - 16 Apr 2009
[Sat Mar 28 12:35:15 2009].../data/System/TimeTablePlugin.txt)
[Sat Mar 28 12:35:15 2009].../data/System/TimelinePlugin.txt)
[Sat Mar 28 12:35:15 2009].../data/System/TreePlugin.txt)
[Sat Mar 28 12:35:15 2009].../data/System/TwistyPlugin.txt) -- Main.CrawfordCurrie - 15 Apr 2009
[Sat Mar 28 12:35:15 2009].../data/Main/SitePreferences.txt)
[Sat Mar 28 12:35:15 2009].../data/Main/WikiGuest.txt)
[Sat Mar 28 12:35:15 2009].../data/Main/WebPreferences.txt)
[Sat Mar 28 12:35:15 2009].../data/Main/WebHome.txt)
[Sat Mar 28 12:35:15 2009].../data/System/InterWikis.txt)
[Sat Mar 28 12:35:15 2009].../data/Main/AdminGroup.txt)
[Sat Mar 28 12:35:15 2009].../data/System/WebPreferences.txt)
[Sat Mar 28 12:35:15 2009].../data/System/SmiliesPlugin.txt)
[Sat Mar 28 12:35:15 2009].../data/Main/WebHome.txt)
of which, only
DefaultPreferences,
SitePreferences,
WikiGuest, (Main|System)WebPreferences,
InterWikis,
AdminGroup and
WebHome are justified.
so, we are reading 26 files, when 8 are needed.
basic pointer for fixing - from
EmptyPlugin.pm
# You must set $NO_PREFS_IN_TOPIC to 0 if you want your plugin to use
# preferences set in the plugin topic. This is required for compatibility
# with older plugins, but imposes a significant performance penalty, and
# is not recommended. Instead, leave $NO_PREFS_IN_TOPIC at 1 and use
# =$Foswiki::cfg= entries set in =LocalSite.cfg=, or if you want the users
# to be able to change settings, then use standard Foswiki preferences that
# can be defined in your %USERSWEB%.SitePreferences and overridden at the web
# and topic level.
our $NO_PREFS_IN_TOPIC = 1;
--
SvenDowideit - 28 Mar 2009
Marked in
red the reads that are still to be eliminated, and marked
the ones that have gone
--
CrawfordCurrie - 15 Apr 2009
Again is the
TargetRelease and
ReleasedIn are not defined in a Waiting for Release item.
Good move. I cannot help wondering. If it is so important that we do not read these setting files - and I do believe this is the case - why do we keep on splitting our perl sources up into more and more small files? That must surely also have a performance hit. Just a thought.
--
KennethLavrsen - 18 Apr 2009
Note: I found that
Item1214 had never been merged over (bug fix). As I merge this over I have decided to make
TablePlugin fully in sync again between current trunk and 1.0.5. This means that this one is merged over with it.
Same with
EditTablePlugin where the GET/Save issue caused a major change in the plugin behaviour and again I found it was important to get better test coverage by having the plugins in sync.
So this one is in 1.0.5 for
TablePlugin and
EditTablePlugin.
--
KennethLavrsen - 18 Apr 2009