[Server] Deck sync identity: schema v41 + proto guid/hash fields

Bumps the schema to v41: master is already at v40, so the deck-sync migration is servatrice_0040_to_0041.sql.
This commit is contained in:
Lukas Brübach 2026-10-11 14:09:05 +02:00
parent e08402ac94
commit 67a36b9828
6 changed files with 70 additions and 2 deletions

View file

@ -14,4 +14,7 @@ message Command_DeckUpload {
reserved 5, 6, 8;
reserved "banner_card_name", "banner_card_provider", "tags";
optional string color_identity = 7;
// Stable per-deck identity for two-way collection sync. Sent on first
// synced upload, echoed back in ServerInfo_DeckStorage_File afterwards.
optional string guid = 9;
}

View file

@ -6,4 +6,9 @@ message Response_DeckDownload {
optional Response_DeckDownload ext = 1007;
}
optional string deck = 1;
// Sync identity echoed so the client can update its sidecar without an
// extra list fetch.
optional string guid = 2;
optional string hash = 3;
optional uint64 last_modified = 4;
}

View file

@ -11,6 +11,15 @@ message ServerInfo_DeckStorage_File {
// Tag names associated with the deck. Empty for decks uploaded before the
// tags column existed.
repeated string tags = 6;
// Stable per-deck identity for two-way collection sync. Empty for decks
// uploaded before the sync migration until they are re-uploaded.
optional string guid = 7;
// Content hash (DeckList::getDeckHash) for change detection without
// downloading the full list.
optional string hash = 8;
// Last modification time, seconds since Unix epoch. Drives newest-wins
// default and conflict-dialog recency highlight.
optional uint64 last_modified = 9;
}
message ServerInfo_DeckStorage_Folder {