Mattflaschen-WMF added a comment.

Adding rc_type or rc_source (which one? these two fields seem largely redundant with each other) to the start of some indexes, so that queries that don't need to look at Wikidata rows can filter them out efficiently

They're not fully redundant, since rc_type for Wikidata is RC_EXTERNAL (from core, thus not Wikidata-specific).

@Catrope and I discussed, and think any new indexes for this purpose should have rc_source.

We should also look into @Catrope's idea of using IN here (but rc_source IN). If this allows using the index effectively, we'd need to add a hook to know about all the rc_source's. Then PHP can convert "not Wikibase" to rc_source IN ('source1', 'source2', 'source3').

Related question, will having multiple such IN clauses (e.g. rc_source IN ('mw.log', 'mw.edit', 'flow') AND rc_source IN ('mw.log', 'mw.edit', 'mw.new' )) affect performance? The EXPLAIN is the same as if they are combined.


TASK DETAIL
https://phabricator.wikimedia.org/T171027

EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Mattflaschen-WMF
Cc: Ankry, Ladsgroup, Lsanabria, Josve05a, Bawolff, greg, Dominicbm, Vriullop, Jmabel, Fae, IKhitron, Johan, Herzi.Pinki, jmatazzoni, Trizek-WMF, Mattflaschen-WMF, KTC, Framawiki, zhuyifei1999, Marostegui, aaron, Andrei_Stroe, Turbojet, Rsocol, Strainu, Jwh, Pyb, Darwinius, Arbnos, Jdforrester-WMF, TheDJ, gerritbot, VladXe, Kf8, Liuxinyu970226, Jay8g, TerraCodes, Iniquity, jcrespo, Reedy, Catrope, Vicpeters, Demidenko, MaxBioHazard, Aklapper, Waytogoeducation, GoranSMilovanovic, Abiyoyo, QZanden, Vali.matei, Jack_who_built_the_house, Minhnv-2809, Poyekhali, Volker_E, Izno, Wong128hk, Luke081515, Wikidata-bugs, Base, aude, GWicke, El_Grafo, Gryllida, putnik, Steinsplitter, Mbch331, Krenair
_______________________________________________
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to