feat(utas-host): real Fifa17IdentityResolver (catalog + store + policy), drop placeholders

This commit is contained in:
funman300
2026-08-11 22:33:40 +00:00
parent 36fe1caa3f
commit 3ef3bc32ec
7 changed files with 253 additions and 99 deletions
+10 -6
View File
@@ -15,9 +15,14 @@ pub struct HostConfig {
pub core_url: String,
/// Directory holding `leagues.json`/`nations.json`/`teams.json`.
pub tables_dir: String,
/// Optional JSON file mapping Core card id → FIFA asset id. Absent = the
/// current reality (no mapping) → Core items cannot render and are dropped.
pub asset_map_path: Option<String>,
/// FIFA 17 card-definition **identity catalog** (card id → FIFA asset id).
/// Required production identity source: a `/club` item's `resourceId` comes
/// from here. Startup fails if it cannot be loaded — never a placeholder.
pub catalog_path: String,
/// Persistent external-identity **store** file (owned-instance → stable wire
/// id). Required: the wire `id` of every owned item is allocated/resolved
/// here so it survives restart and reverses exactly.
pub identity_store_path: String,
}
#[derive(Debug)]
@@ -46,9 +51,8 @@ impl HostConfig {
.unwrap_or_else(|_| "http://127.0.0.1:8080".into()),
tables_dir: env::var("OPENFUT_FIFA17_TABLES_DIR")
.unwrap_or_else(|_| "fifa17-recon/data/tables".into()),
asset_map_path: env::var("OPENFUT_FIFA17_ASSET_MAP")
.ok()
.filter(|s| !s.is_empty()),
catalog_path: required("OPENFUT_FIFA17_CATALOG")?,
identity_store_path: required("OPENFUT_IDENTITY_STORE")?,
})
}
}