Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mirroring a wiki #35

Closed
33 of 34 tasks
lahwaacz opened this issue Jul 5, 2016 · 2 comments
Closed
33 of 34 tasks

Mirroring a wiki #35

lahwaacz opened this issue Jul 5, 2016 · 2 comments
Assignees
Labels
Milestone

Comments

@lahwaacz
Copy link
Owner

lahwaacz commented Jul 5, 2016

References:

To do list:

  • abstraction for working with an SQL database
  • grabbers for fetching important tables from API
    • namespace, namespace_name (custom tables)
    • recentchanges, logging
    • user, user_groups, ipblocks
    • page, page_props, page_restrictions, protected_titles
    • archive, revision, text: wait for list=allrevisions module in MediaWiki 1.27 https://phabricator.wikimedia.org/T113885
    • tags
    • interwiki
  • handle difficult actions involving DELETE or UPDATE queries as part of the syncing process:
    • removing from user groups
    • unblock
    • unprotect
    • delete (move from revision to archive)
    • undelete (move from archive to revision, also check page_id)
    • selective undelete
    • merge (works assuming that both source and target page were not deleted before the sync)
    • import (works assuming that the imported pages were not deleted/merged/whatever before the sync)
    • delete/revision, delete/event
    • tag/update (separately for recentchanges, logging, revision, archive)
    • other log events: https://wiki.archlinux.org/api.php?action=help&modules=query%2Blogevents
  • let the SQL database serve as a source of data instead of the API
    • list=recentchanges
    • list=logevents
    • list=allpages
    • list=protectedtitles
    • list=allrevisions
    • list=alldeletedrevisions
    • titles=, pageids= for use with prop=
    • common executor for the DB select queries (for easy profiling)
  • framework for tests
    • pytest fixture for web server (nginx)
    • pytest fixture for php-fpm
    • pytest fixture for MediaWiki installation (depends on nginx, php-fpm, postgresql + MW sources, config, initial SQL)
    • write the tests...
    • implement a double-source wrapper, which yields from the API and checks the DB selects, ignoring NotImplementedErrors etc. (usable for unit tests as well as real-world testing) split into Double-source wrapper for API and DB queries #50
@lahwaacz lahwaacz added this to the someday maybe milestone Jul 5, 2016
@lahwaacz lahwaacz self-assigned this Jul 5, 2016
@lahwaacz
Copy link
Owner Author

lahwaacz commented Aug 5, 2018

This is somewhat finished and working nicely, so it's time to close this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant