Extend Article instead of using a hook, and other refactoring

GlobalUserpage now extends Article, and consolidates all of the logic
that checks whether a page is enabled is in GlobalUserpage::isGlobal().

The caching structure was also re-designed to make it easier to invalidate
upon edits.

Misc. fixes:
* Created $wgGlobalUserpageDBname instead of using $wgSharedDB
* Set a negative cache if there is no global page to use

Change-Id: I73ac36e6f9d3e4dfc21f518645bf8691bb6d9274