feat(server): sync.LogChange helper + EntityType/Op constants

New package internal/sync. LogChange writes a library_changes row inside
the supplied tx. Encode helpers produce stable composite ids for like_*
and playlist_track entries. Subsequent commits wire LogChange into the
scanner / likes / playlists services.

Also: dbtest.dataTables now includes library_changes so test isolation
holds across runs.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-05-09 22:29:51 -04:00
parent cb35133843
commit 3959c85111
4 changed files with 169 additions and 0 deletions
+1
View File
@@ -54,6 +54,7 @@ var dataTables = []string{
"lidarr_quarantine",
"playlist_tracks",
"playlists",
"library_changes", // M7 #357 — must reset to keep cursor isolated per test
"tracks",
"albums",
"artists",