Skip to Content.
Sympa Menu

devel - [sympa-dev] Optimizing / authorization scenarios management

Subject: Developers of Sympa

List archive

Chronological Thread  
  • From: Olivier Salaün <address@concealed>
  • To: address@concealed
  • Subject: [sympa-dev] Optimizing / authorization scenarios management
  • Date: Tue, 07 Aug 2007 11:51:26 +0200

Hello,

We've reorganized the code of Sympa to change the way authorization scenarios are managed. The goal was to reduce the amount of memory consumed by Sympa processes. The idea came from Sergiy Zhuk who had noticed that scenarios used by each list were duplicated in memory.

We've moved the authorization-related subroutines out of List.pm and moved them to a new Scenario.pm module.
Authorization scenarios are now loaded as 'Scenario' perl objects in a central hash in memory, the key being the file path. List configuration structure then refer to these scenarios via the same file path (thus avoiding any disturbances of the 'config.bin management.

The scenario are now reloaded whenever they change on disk, except for operations that require good performances (like the 'lists' command). Inclusion of third party scenarios is now performed at evaluation time (in request_action()) and not while loading the scenario as it used to be.


The results (in an environment with 800 lists) : we've noted that sympa processes are slimmer (from 95Mb to 65Mb). The config.bin files are, of course, also smaller (from 16Kb to 4Kb). Performances are almost the same.

These changes + the previous optimizations are part of sympa 5.4a.2. We are currently running this version on our own server for validation purpose.
You can evaluate this version : http://www.sympa.org/distribution/


  • [sympa-dev] Optimizing / authorization scenarios management, Olivier Salaün, 08/07/2007

Archive powered by MHonArc 2.6.19+.

Top of Page