Manual:Architectural modules

From mediawiki.org

One of the ways to describe the software architecture of a system is to describe its module structures and the relationships between them. Modules show the way a system is decomposed into manageable units, what services these units use from each other and how those units are combined into larger ensembles. Modules are characterized by a set of responsibilities, separate classes or packages are grouped into modules based on these shared responsibilities. [1]

Modules in MediaWiki[edit]

In order to describe MediaWiki's architecture and provide an overview of different parts of the system, identified MediaWiki modules were gathered in Category:Architectural modules of MediaWiki. Every module in this category is described by presenting two properties:

  • Responsibilities - the role of the module in the system
  • Implementation information - implementation details (mapping to source code units)

During the initial stage only some key modules were described. The reason for selection of these initial modules is their high-level presence in the fulfillment of a basic request to show a page. On the figure below we can see a flowchart that represents a sequential participation of modules during the execution of a request. Every request is received by index.php, where an object MediaWiki is created. After that a Page from Page module is initialized together with an Action that will be performed on it (from Action module). Depending on the Action several other modules can participate in the request execution. If it is a view request for a normal article, than either Parser module to parse the page or Cache module to retrieve the page from cache will be called. The Cache module is responsible for many types of caching, but at this point of request processing only the parser cache is relevant. Eventually an OutputPage object will be filled with necessary data coming from Parser or Cache and the Skin module will take care of its output as an HTML.

developer documentation for index.php entry pointarchitectural documentation for MediaWiki modulearchitectural documentation for Page modulearchitectural documentation for Action modulegenerated documentation for ViewAction classarchitectural documentation for Parser modulearchitural documentation for Cache modulearchitectural documentation for OutputPage modulearchitectural documentation for Skin module
Basic modules participating in the "view" request, click each for more documentation. White rectangles represent modules comprised of a single object (implemented as a single class). Gray rectangles represent modules that are implemented by several classes. Rectangle with dashed border represents extension class of the class with solid border.

Further elaboration of these modules as well as description of many other modules in MediaWiki is required in order to produce a complete and comprehensive software architecture documentation of MediaWiki software.

See also[edit]

References[edit]

  1. Clements et al., Documenting Software Architectures: Views and Beyond