LiquidThreads 3.0/Phase 1

This is the page for the "backend" phase, which is Phase 1 of the LiquidThreads re-engineering project. This work package is managed by Alolita Sharma, and is lead by the LiquidThreads lead developer, Andrew Garrett. It was originally written after Phase 1A was completed, and the timeline focusses on the plan for Phase 1B.

Rationale
The existing LiquidThreads data model was designed with a very different LiquidThreads in mind. Certain design decisions that were made that need to be revisited. For a full discussion of the shortcomings of the existing LiquidThreads data model, see this page.

Objectives
The objectives of this phase are:


 * to provide short term relief from the bugs that have been occurring in LiquidThreads instances running across Wikimedia Foundation projects.
 * to, as soon as possible, bring the new LiquidThreads object model into production testing, so that it can be tested independently of interaction changes.
 * to provide a stable, flexible and well-documented platform upon which future changes to LiquidThreads can be built.

Scope
This timeline includes the following work:


 * Development of the new LiquidThreads data model (already completed)
 * Cosmetic refactoring of the LiquidThreads controller/display model. In general, this will involve abstracting the data model away from the display logic. It will not be exhaustive, and is intended primarily to facilitate the following step.
 * Modification of LiquidThreads controller logic to use the new data model.
 * The implementation of a new post submission and editing form (since the old form will no longer work with existing infrastructure).
 * The implementation of an appropriate migration path for old databases using the existing schema.

This timeline excludes the following work:


 * Any improvements to LiquidThreads interaction.
 * The implementation of an improved "new messages" system.
 * Changes to the fundamental structure of the controller and display
 * Re-implementation of comment search functionality. For the time being, this feature will be removed.

Phase 1A
Phase 1A is the design and development of a new data model for LiquidThreads. As of early April 2011, this part has been completed, except for the code-level feedback process.

This phase included:


 * Surveying the problems presented by the existing data model.
 * Determining whether or not a data model rewrite was advisable.
 * Soliciting input on data and structures that needed to be stored.
 * Producing and iterating a data model design.
 * Soliciting feedback on the data model design.
 * Producing a database schema.
 * Writing data classes to provide a standardised interface through which thread data can be accessed.
 * Testing and iterating on the data classes.

To complete this phase, code-level feedback is being solicited on the completed data model.

Phase 1B
Phase 1B is the integration of a fully developed data model into the LiquidThreads codebase. It is being begun at Easter 2011. As a general principle, integration work will be done before migration and related work, due to the possibility of the data model changing due to problems surfaced in the integration process.

Timelines are approximate, possibly underestimates, and assume that Andrew Garrett is the only developer assigned to this project. They take into account the following probable disruptions:

This phase includes the following work:
 * Andrew is working on another large project at Cancer Council Australia, which concludes in late June to mid July.
 * Andrew is a university student, and his general availability will be limited throughout June due to examinations.


 * Identifying code that currently references the existing data model. Complete.
 * Writing a new display class based on existing display logic, and modifying the display code to use the new data model. Timeline: Before May 1
 * Writing a new post submission/edit form. Timeline: Before May 8
 * Abstracting and updating the action pages (Post, reply, edit, split, merge, move, delete). Timeline: Before May 15
 * Updating the API modules to use the abstracted actions and new data model. Timeline: Before May 15


 * Writing a new history view for topics and comments. Timeline: Before May 30
 * Re-integrating the new object model with the new message notification subsystem. Timeline: Before June 7


 * Rewriting log page and Recent Changes integration. Timeline: Before June 30
 * Implementing a database migration script. Timeline: Before June 30
 * Writing a new integration with the XML dump infrastructure (may need discussion). Timeline: Unknown
 * Implementing subsystem for leaving traces and adding reactions (trade-out item). Timeline: Unknown

Phase 1C
Phase 1C is a phased test deployment of LiquidThreads with its new backend. It is scheduled to begin on July 1 with a branch merge of the work from Phase 1B.

It includes the following work:


 * Merging the lqt-rewrite branch to trunk. Timeline: July 1
 * Phased test deployment of LiquidThreads to TranslateWiki, then test.wikipedia.org, then MediaWiki.org.
 * Production deployment of LiquidThreads with its improved backend to all Wikimedia wikis using LiquidThreads. Timeline: Before Wikimania, August 2.