Page MenuHomePhabricator

๐Ÿ”๐Ÿ›  Separate property data type lookup from the โ€œStoreโ€ service
Closed, ResolvedPublic8 Estimated Story Points

Description

In order to enable custom value parsers for certain data types (T359421) we need to look up the corresponding Property's data type whenever a statement/qualifier/reference value is parsed. This currently results in a circular dependency in Wikibase:

  • Store depends on Deserialization (because the DB contains serialized entities and we want Store services to return data model objects, not JSON/arrays)
  • PropertyDataTypeLookup is part of Store
  • we now create a "data type aware value deserializer" which is part of deserialization but depends on Store via PropertyDataTypeLookup
  • Store <- Deserialization <- Store <- ... โ™ป๏ธ

The goal would be to start with the following approach and only if that doesn't work we'd implement the second approach

Approach #1

Approach #2

  • separate the existing PropertyDataTypeLookup from Store
    • means we need to rethink the EntityRetrievingDataTypeLookup because it encompasses the full circular dependency within a single class

Event Timeline

Restricted Application added a subscriber: Aklapper. ยท View Herald TranscriptMar 6 2024, 4:38 PM
Dima_Koushha_WMDE renamed this task from Separate property data type lookup from the โ€œStoreโ€ service to ๐Ÿ”๐Ÿ›  Separate property data type lookup from the โ€œStoreโ€ service.Mar 20 2024, 4:10 PM