|mediawiki/extensions/HitCounters : master||Add PostgreSQL support to HitCounters|
|· · ·|
|Invalid||None||T2384 [REPLACED BY TAG] PostgreSQL/pgsql support (tracking)|
|Open||None||T110655 Extension HitCounters: Add PostgreSQL support|
|Resolved||Kghbln||T109180 HitCounters doesn't update new Page IDs|
|· · ·|
You can have a look at my change https://gerrit.wikimedia.org/r/#/c/98353/ to VoteNY.
I've had a brief look at HitCounters and I think it tries to overcomplicate things in order to avoid
some MySQL issues. For PostgreSQL it could be probably much simpler.
To create a proper table for this extension one needs to understand this: http://git.wikimedia.org/blob/mediawiki%2Fextensions%2FHitCounters.git/f29d4e370dfb25844fc320c3f20712f07b0efa1e/ViewCountUpdate.php;jsessionid=dgzex25xwojg197eydhgpym98#L50 and this: http://git.wikimedia.org/blob/mediawiki%2Fextensions%2FHitCounters.git/f29d4e370dfb25844fc320c3f20712f07b0efa1e/ViewCountUpdate.php;jsessionid=dgzex25xwojg197eydhgpym98#L104
I think this code can be actually simplified for PostgreSQL so such elaborate dancing is not really necessary.
I don't know of one, but this would be a very good thing to address.
Looking at saper's code, I would recommend that .sql be the extension for mysql (since MySQL and SQLite tend to share it and MySQL is WMF's default target.
Otherwise, I think this would be a great topic for discussion at this week's stakeholders' meeting.
The dropping of column page.page_counter was added to all the database updater scripts for 1.25, but then the dropping was taken out just for MySQL and put back in for 1.26.
It seems to me that that makes it impossible to update a pre 1.25 installation without losing the hit count values for any database other than MySQL. Does that sound correct?
Even for MySQL, it seems like you can't go from one LTS to another (1.23 to 1.27) without stopping at an EOL'ed version in between.