Make elementId into a composite of entryId and the ordering number #97

Closed
opened 2026-04-08 08:35:37 +02:00 by oysteikt · 1 comment
Owner

Once we start providing regular updates, the current incremental way we generate elementIds right now will become a huge point of contention. Since JMdict adds entries in the middle (and likely close to the start) of the dictionary data, everything after will shift and everything that references the elementIds will also need to be updated.

Instead, we should make some sort of key like entryId.orderingNum, which is likely fine since we roughly know an upper limit for the sense count. Things will still shift when new senses are added, but it will be a lot better than what we're doing now

Related to, but still independent from #96, #95, #6

Once we start providing regular updates, the current incremental way we generate `elementId`s right now will become a huge point of contention. Since JMdict adds entries in the middle (and likely close to the start) of the dictionary data, everything after will shift and everything that references the `elementId`s will also need to be updated. Instead, we should make some sort of key like `entryId.orderingNum`, which is likely fine since we roughly know an upper limit for the sense count. Things will still shift when new senses are added, but it will be a lot better than what we're doing now Related to, but still independent from #96, #95, #6
oysteikt added the space-reduction label 2026-04-08 08:35:37 +02:00
oysteikt added this to the Kanban project 2026-04-08 08:35:37 +02:00
Author
Owner

Note: same for senses

Note: same for senses
oysteikt moved this to Finished in Kanban on 2026-04-08 12:57:45 +02:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: mugiten/jadb#97