Skip to main content

implement-browser-storage-migration

Implement a browser-storage migration with versioned schemas, privacy controls, idempotent conversion, cross-tab coordination, rollback, and corrupted-state recovery. Use when changing cookies, local storage, session storage, IndexedDB, or cached client data.

来源信息

仓库
protosphinx/sphinxstack
最近来源活动
2026年7月29日 13:55
检测到的 SKILL.md 语言
英语
星标
3
Forks
0

安装方式

默认使用会先检查来源的 Prompt;你也可以切换为直接命令,或下载本地副本。

检查来源文件

决定是否安装前,请先阅读 SKILL.md,以及 SkillsMP 当前展示的配套文件。

文件资源管理器
2 个文件

正在显示 SKILL.md

SKILL.md
来源说明 · 只读预览
name
implement-browser-storage-migration
category
web
description
Implement a browser-storage migration with versioned schemas, privacy controls, idempotent conversion, cross-tab coordination, rollback, and corrupted-state recovery. Use when changing cookies, local storage, session storage, IndexedDB, or cached client data.
# implement-browser-storage-migration Treat every client as an independent, interruptible migration. ## When to use - Use for schema changes, storage-engine moves, key renames, encryption changes, or data minimization. - Do not copy credentials, secrets, or data beyond its consent and retention purpose. ## Procedure 1. Inventory keys, schemas, sizes, owners, sensitivity, consent, retention, browser support, and code consumers. 2. Define old and new versions, valid states, invariants, transformation, default, deletion, and rollback compatibility. 3. Make migration idempotent and resumable with a committed version marker only after validation. 4. Coordinate multiple tabs and workers through a lease or version check; fence stale writers. 5. Preserve data required for continuity while minimizing, expiring, or deleting obsolete fields. 6. Handle quota, private mode, blocked storage, partial write, corrupted data, old client, offline, and interrupted update. 7. Roll out by cohort with telemetry that avoids payload contents and identifies version or failure class. 8. Test upgrade, downgrade, reload, cross-tab, account switch, logout, deletion request, rollback, and recovery. ## Done - A storage migration document records schemas, versions, transformations, privacy, ownership, fencing, cohorts, and recovery rules - Upgrade, interruption, corruption, quota, cross-tab, logout, deletion, old-client, and rollback tests verify data integrity
在 GitHub 查看