Translatewiki.net uses SMW for the following:
- To store locations of translators in order to display maps of translators (overall or per project)
- Support request tracking system
Challenges to run SMW at translatewiki.net include:
- Unique operational issues such as bringing the site down if smw.json version does not match code version
- Bugs and performance issues in SMW, e.g. locking editing of categories indefinitely due to broken change propagation
- Frequent work needed to address deprecation warnings. SMW is hosted on GitHub, so it doesn't get the automatic changes often done for extensions in Gerrit
In terms of impact on our productivity, the last one is most severe. We have spend a lot of engineering resources to submit fixes upstream.
Cost benefit evaluation
The support tracking system got broken when LiquidThreads thread summarization feature broke many years ago. We have instead of started directing support requests directly to the upstream projects. This might not be ideal, but this means we don't need to worry about supporting this system, and in fact we have already stopped using SMW for that: https://translatewiki.net/w/i.php?title=Template:Support&diff=prev&oldid=11907856
The other use case is for maps. The Maps are displayed by the Maps extension, but we use SMW's convenient query facilities to get the list of items to display. This can be reasonably replaced with a custom implementation using page props, for example.
To mitigate the issues, we have two options (besides the status quo): get other people to improve SMW, or stop using SMW. It may be possible that SMW moves to Wikimedia Gerrit, or more likely to Wikimedia GitLab, in the future, benefiting from automatic deprecation patches like other code we use. Maybe more people will even contribute to fix the operational issues and bugs, but there is no guarantee of that.
To stop using SMW, we only need limited effort that is smaller than all the work we have contributed to upstream so far. This will certainly address all the issues listed above, which makes it favorable solution in context of translatewiki.net (not necessarily in the larger MediaWiki ecosystem).
TODO
- Implement alternative solutions for features using SMW
- Migrate features away from SMW
- Remove all SMW related pages (Property and smw/schema namespaces)
- https://translatewiki.net/wiki/Special:AllPages?from=&to=&namespace=212
- https://translatewiki.net/wiki/Special:AllPages?from=&to=&namespace=202
- Uninstall SMW extension
- Remove SMW database tables (setupStore.php --delete in old deployment should work)
- Drop local patch f47cfd903e31e78c3c972ad448ec168e24fd4132
Gotchas
- Local patch sha had changed, should have used title instead
- Missed some SMW related settings. Should have grepped for "smw" as well.
- Fatals from parser cache. Fixed by setting $wgCacheEpoc
- Canary broke when removed SemanticMediaWiki directory due to autoload still trying to load stuff from there. Had to rm vendor directory and start from scratch.
- We expected deployment to take 30 minutes, we reserved 60 minutes, and took 75 minutes.