Addshore added a comment.

I have no idea what you are doing (this is not a complain, I just do not understand it).

Most of what the extension is doign was in the IRC chat (I can't find it to add it to this ticket)
The short description @ https://www.mediawiki.org/wiki/Extension:Cognate should help. Also the testing system may help.

Once you have a final proposal, send a gerrit review and I will give it another look.

The extension is already entirely written, and will work with any of the schemas listed in this ticket.
As it is unclear which of the schemas you prefer (considering the team here doesn't really like the sound of T148988#2744793) I don't really have a clear path forward.

Something that usually helps is https://en.wikipedia.org/wiki/Entity%E2%80%93relationship_model and writing realistic, large example data.

I think an ER diagram for these concepts is overly complicating things. The only thing the extension knows about are sites, titles, and a normalized title string.

  • A site has a dbname and an interwiki prefix
  • A title has a site, namespace and value(page_title in terms of mediawiki)
  • A titles value also exists in a normalized form, this normalization step is the same for ALL sites. 99.9% of the time the normalization step outputs the exact same title value string that was input.

As for queries:

  • DELETES will always happen using a site dbname, namespace, and title_value
  • SELECTS will always happen using a namespace and the normalized title_value

As for uniqueness:

  • site,namespace,title will always be unique
  • site,namespace,normalized_title will NOT always be unique

As I am struggling to grasp a clear path forward from this ticket so far I will likely push ahead with T148988#2763922 as from this side this makes the most sense (given the comments above and our understanding of the extension). This schema is very similar to the one currently in the extension with the addition of the sites table and the NULL values in the title field where the title is the same as the normalized title (to cut back on duplicated data)
As for the PKs I will simply go for the initial PK over everything for now.

And then I guess we can look through all of this again in a few more weeks.


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

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

To: Addshore
Cc: daniel, Tobi_WMDE_SW, hoo, Aklapper, jcrespo, Addshore, Marostegui, Minhnv-2809, D3r1ck01, Izno, Luke081515, Wikidata-bugs, aude, Darkdadaah, Mbch331, Jay8g, Krenair
_______________________________________________
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to