Page MenuHomePhabricator

Remove numeric entity IDs from database schema
Closed, ResolvedPublic

Description

If we want to be able to use non-numeric entity IDs, we need to change our database schema to no longer use integer columns for representing entity IDs. The following tables are still using integer IDs:

  • wb_entity_per_page - killed
  • wb_items_per_site - not doing
  • wb_terms - being killed

Related Objects

StatusSubtypeAssignedTask
OpenNone
Resolvedhoo
DeclinedNone
InvalidLydia_Pintscher
ResolvedLadsgroup
ResolvedAddshore
ResolvedLadsgroup
Resolvedadrianheine
Resolveddaniel
ResolvedLadsgroup
ResolvedLadsgroup
ResolvedLadsgroup
Resolvedhoo
Resolvedhoo
Resolvedhoo
Resolvedhoo
DeclinedNone
ResolvedLydia_Pintscher
ResolvedNone
ResolvedWMDE-leszek
DeclinedNone
DeclinedNone
DeclinedNone
ResolvedLadsgroup
Resolvedaude
ResolvedMarostegui
ResolvedLadsgroup
ResolvedAndrew
ResolvedLadsgroup
Resolvedaude
ResolvedLadsgroup
ResolvedLadsgroup
ResolvedLadsgroup
ResolvedMarostegui
ResolvedAndrew
DeclinedNone

Event Timeline

daniel raised the priority of this task from to Needs Triage.
daniel updated the task description. (Show Details)
daniel added a subscriber: daniel.
Danny_B renamed this task from [tracking] Remove numeric entity IDs from database schema to Remove numeric entity IDs from database schema (tracking).May 27 2016, 5:46 PM
Phabricator_maintenance renamed this task from Remove numeric entity IDs from database schema (tracking) to Remove numeric entity IDs from database schema.Aug 13 2016, 11:22 PM
thiemowmde added a subscriber: thiemowmde.

I believe we all know about these and we have migration paths for all of them.

wb_terms is being killed, the new tables for storing terms do use numeric ids, but each table is specific to items / properties, which are fine with having numeric ids. so we don't need to fix that area any further.
https://github.com/wikimedia/mediawiki-extensions-Wikibase/blob/cd4957f2f0d5f54d565f065bcd134a1acbc33234/repo/sql/AddNormalizedTermsTablesDDL.sql

Addshore claimed this task.

Going to mark this as resolved.
We need not fix items per site (at least we have no reason to right now), items right now will always be representable as an integer and a prefix so can be represented as just an int in a table specific to them.
This is the same reasoning we have for only using ints in the new refactored terms storage tables where the table is specific to items.