4d520ab0e3
- jellyfin-service-registry: proposal, design, and tasks for completing the Jellyfin migration off machine-level config. - grafana-prometheus-polish: proposal, design, and tasks for improving the Grafana/Prometheus observability integration. Both are planning-only artifacts; implementation not started.
2.6 KiB
2.6 KiB
Design — Jellyfin service-registry migration (completion)
Change: jellyfin-service-registry
Phase: design
Date: 2026-06-23
Current state
- Jellyfin/Jellyseerr service definitions exist in
integrations/jellyfin.pyandintegrations/jellyseerr.py. dependencies.pyresolves Jellyfin clients from service records viajellyfin_service_id.- Frontend pages already select Jellyfin services via
useServiceInstances("jellyfin"). settings_store.pystill defaults machineservicesto["monitoring", "files", "jellyfin"]and persistsmedia_root/path_prefix.MonitoringMachine/MonitoringMachineInputtypes still includemedia_rootandpath_prefix.Settings.tsxstill rendersmedia_rootandpath_prefixinputs and listsjellyfinas a service option.path_utils.pystill has path-mapping helpers, but the callers infiles.pyno longer depend on machine-levelmedia_root/path_prefix.
Target state
Backend
DEFAULT_SERVICESbecomes["monitoring", "files"].settings_store.pydropsmedia_rootandpath_prefixfrom_normalize_machine_payload,_row_to_machine, the machine table schema, and default seeding.- Add
DROP TABLE IF EXISTS ...orALTER TABLE DROP COLUMNcleanup as needed for existing databases (SQLite has limitedDROP COLUMNsupport; prefer table rebuild or leave harmless columns). path_utils.pyis reviewed; if no callers remain, delete the module. If callers remain, ensure they do not reference machine fields.routers/files.pyconfirmed to not read machinemedia_root/path_prefix.- Tests updated to remove
media_root/path_prefixfrom fixtures.
Frontend
- Remove
media_rootandpath_prefixfromMonitoringMachineandMonitoringMachineInputintypes/index.ts. - Remove
jellyfinfrom the machine services multi-select inSettings.tsx. - Remove
media_rootandpath_prefixinputs from the machine editor. - Update
emptyMachine()to not include these fields. - Update tests/fixtures.
Docs
docs/REQUIREMENTS.md— update the machine config description to remove Jellyfin/path-prefix fields.CHANGELOG.md— breaking note about removed machine fields.
Slices
- Backend cleanup —
settings_store.py,config.py(if any env vars),path_utils.py, tests. - Frontend cleanup — types,
Settings.tsx, tests. - Docs + changelog.
Risks
- Existing DB rows may have
media_root/path_prefixvalues; dropping columns is safe but irreversible. Backups recommended. path_utils.pymay still be referenced by archive code; verify only live code is affected.